ÏÂÁî×¢²á±íÔõô·¿ª³ÌÐò
Ҫͨ¹ýÏÂÁî×¢²á±í·¿ª³ÌÐò£¬ÐèÒª×ñÕÕÒÔÏ°취£º·¿ªÏÂÁîÌáÐÑ·û¡£µ¼º½µ½³ÌÐòËùÔÚÎļþ¼Ð¡£ÔËÐгÌÐò£¬²¢ÔÚÐëҪʱת´ï²ÎÊý¡£
ÔõÑùͨ¹ýÏÂÁî×¢²á±í·¿ª³ÌÐò
ҪʹÓÃÏÂÁî×¢²á±í·¿ª³ÌÐò£¬¿ÉÒÔʹÓÃÒÔÏ°취£º
°ì·¨ 1£º·¿ªÏÂÁîÌáÐÑ·û
ÔÚ Windows ÖУ¬°´ Windows ¼ü + R ·¿ª¡°ÔËÐС±¶Ô»°¿ò¡£
ÔÚ¡°ÔËÐС±¶Ô»°¿òÖУ¬ÊäÈë¡°cmd¡±²¢°´»Ø³µ¼ü¡£
°ì·¨ 2£ºµ¼º½µ½³ÌÐòËùÔÚÎļþ¼Ð
ÔÚÏÂÁîÌáÐÑ·û´°¿ÚÖУ¬Ê¹Óà cd ÏÂÁîµ¼º½µ½°üÀ¨Òª·¿ªµÄ³ÌÐòµÄ¿ÉÖ´ÐÐÎļþ£¨Í¨³£ÒÔ .exe ×îºó£©µÄÎļþ¼Ð¡£
ÀýÈ磬Ҫ·¿ªÎ»ÓÚ¡°C:\Program Files\MyProgram¡±Îļþ¼ÐÖеġ°MyProgram.exe¡±Îļþ£¬ÇëÊäÈëÒÔÏÂÏÂÁ
cd C:\Program Files\MyProgram
µÇ¼ºó¸´ÖÆ
°ì·¨ 3£ºÔËÐгÌÐò
ʹÓÃÒÔÏÂÓï·¨ÔËÐпÉÖ´ÐÐÎļþ£¨³ÌÐò£©£º
program_name
µÇ¼ºó¸´ÖÆ
Ìæ»»¡°program_name¡±Îª¿ÉÖ´ÐÐÎļþµÄÃû³Æ£¨²»°üÀ¨ºó׺Ãû£©¡£
ÀýÈ磬ҪÔËÐС°MyProgram.exe¡±Îļþ£¬ÇëÊäÈëÒÔÏÂÏÂÁ
MyProgram
µÇ¼ºó¸´ÖÆ
°ì·¨ 4£º¿ÉÑ¡£º×ª´ï²ÎÊý
ijЩ³ÌÐò¿ÉÄÜ»á½ÓÊÜÏÂÁîÐвÎÊý£¬ÕâЩ²ÎÊý¿ÉÒԸıä³ÌÐòµÄÐÐΪ¡£
Ҫת´ï²ÎÊý£¬ÇëÔÚ¿ÉÖ´ÐÐÎļþÃûºó¸½¼Ó²ÎÊý£¬ÓÿոñÍÑÀë¡£
ÀýÈ磬ҪʹÓòÎÊý¡°–help¡±ÔËÐС°MyProgram.exe¡±Îļþ£¬ÇëÊäÈëÒÔÏÂÏÂÁ
MyProgram --help
µÇ¼ºó¸´ÖÆ
Ö´ÐÐÕâЩ°ì·¨ºó£¬¸Ã³ÌÐò½«Ê¹ÓÃÄúÖ¸¶¨µÄ²ÎÊý·¿ª¡£
ÒÔÉϾÍÊÇÏÂÁî×¢²á±íÔõô·¿ª³ÌÐòµÄÏêϸÄÚÈÝ£¬¸ü¶àÇë¹Ø×¢±¾ÍøÄÚÆäËüÏà¹ØÎÄÕ£¡