START ["ã¿ã¤ãã«"] [/D ãã¹] [/I] [/MIN] [/MAX] [/SEPARATE | /SHARED] [/LOW | /NORMAL | /HIGH | /REALTIME | /ABOVENORMAL | /BELOWNORMAL] [/AFFINITY <16é²æ°ã®é¢ä¿ãã¹ã¯>] [/WAIT] [/B] [ã³ãã³ã/ããã°ã©ã ] [ãã©ã¡ã¼ã¿]
ããã©ã«ãã§ã¯ã¨ã³ã¼æ©è½ã¯ãªã³ã«ãªã£ã¦ãã¾ããããããã¡ã¤ã«ãå®è¡ããã¨æ¬¡ã®ããã«è¡¨ç¤ºããã¾ãã ã¨ã³ã¼æ©è½ããªã³ã«ãªã£ã¦ããã¨ãããããã¡ã¤ã«ã§å®è¡ããã cd:\test ã dir ãªã©å®è¡ããã³ãã³ã(ããã³ããã³ãã)ãç»é¢ã«è¡¨ç¤ºããã¾ãã å ´åã«ãã£ã¦ã¯å®è¡ãã¦ããã³ãã³ãã¯è¡¨ç¤ºããã«çµæã ã表示ãããå ´åãããã¾ãããã®å ´åã¯ã¨ã³ã¼æ©è½ããªãã«ãã¦ãã ãããã¨ã³ã¼æ©è½ããªãã«ããæ¹æ³ã¯2ã¤ç¨æããã¦ãã¾ãã®ã§ãããã確èªãã¦ã¿ã¾ãã ã³ãã³ãã®åã«@ãã¤ãã¦ã¨ã³ã¼æ©è½ããªãã«ãã ã¨ã³ã¼æ©è½ããªãã«ãã1ã¤ç®ã®æ¹æ³ã¯å®è¡ããã³ãã³ãã®åã« @ ãè¨è¿°ãã¾ããå ç¨ã®ããããã¡ã¤ã«ãå°ãå¤æ´ãã次ã®ããã«åã³ãã³ãã®åã« @ ãä»ãã¾ããã
対象èªè ãWindowsç°å¢å¤æ°ã®è¶ åºæ¬ãç解ããçºã®ã¢ããã¼ããã®è¨äºããä½ã¨ãªãã«ãªã³ã¯ãè¸ãã æ¹ã ç°å¢å¤æ°ã¨ãããã®ãä½ã¨ãªãããã£ãã®ã§ãSETXããä½ã¨ãæå¹å©ç¨ãããã¨æã£ã¦ããåå¦è ã ãããããããããSETãã«æ¯ãçãããSETXãã ãï½ï¼ã¨é«ãæ¬ã£ã¦ããä¸ç´è ã ç°å¢å¤æ°ã«ä¸å®¶è¨ããã¤ä¸ç´è ï¼âè¦å¯ï¼ã ä¼ãããã㨠æ²é¡éãã æè¨ã®ãå¼ç§°ãã«ã¤ãã¦åç½®ã Windowsã¬ã¸ã¹ããªã®ããã¼ã㯠ç°å¢å¤æ°ã«ããããå¤æ°ããå¤ãã«ç½®ãæãã㨠ãSET HOGE=fugaãã®HOGEããå¤ããfugaãããã¼ã¿ãã¨å¼ã¶ããã§ãã æ¬ç¨¿ã§ã¯ã¬ã¸ã¹ããªã®è©±ãå°ãã ãåºã¦ããã®ã§ã ç°å¢å¤æ°ä¸ã®ãå¤æ°ï¼HOGEï¼ããªããã¬ã¸ã¹ããªä¸ã®ãå¤ãã§ããæã®ã左辺ããã¾ã¨ã㦠便å®ä¸ãæ¬ç¨¿ã§ã¯ããã¼å¤ãã¨å¼ç§°ãã¾ãã ã¾ããç°å¢å¤æ°ä¸ã®ãå¤ï¼fugaï¼ããã¬ã¸ã¹ããªä¸ã®ããã¼ã¿ãã§
ãã®ãã¼ã¸ã§ã¯ãããããã¡ã¤ã«ã«é »åºããifã³ãã³ãã«ã¤ãã¦ã詳細ãªè§£èª¬ãè¡ã£ã¦ãã¾ãã ifã³ãã³ãã«ã¯æ§ã ãªä½¿ç¨å½¢æ ãããã®ã§ãä¹ ã ã«ãããã使ãã¨ããåãã¦ãããã使ãã¨ãã«æ¸æããã¨ããããã¨æãã¾ãã ãããªã¨ãã«ã¯ãæ¯éãã®ãã¼ã¸ãã覧ä¸ããã #ç®æ¬¡ ï¼ï¼ifã³ãã³ãã®åºæ¬ ï¼ï¼ifã³ãã³ãã®æ§æâ ï½ == ï½ ï¼ï¼ifã³ãã³ãã®æ§æâ¡ï½ æ¯è¼æ¼ç® ï½ ï¼ï¼ifã³ãã³ãã®æ§æâ¢ï½ errorlevel ï½ ï¼ï¼ifã³ãã³ãã®æ§æâ£ï½ exist ï½ ï¼ï¼ifã³ãã³ãã®æ§æâ¤ï½ defined ï½ ï¼ï¼ifã³ãã³ãã®æ§æâ¥ï½ cmdextversion ï½ ï¼ï¼ifã³ãã³ãã®æ³¨æç¹ã»å¿ç¨ ï¼ï¼==ã¨equã®éã ï¼ï¼ifæã®å ¥ãåã«ã¯æ°ãä»ããã ï¼ï¼ã¾ã¨ã #1.ifã³ãã³ãã®åºæ¬ ifæã¨ã¯ã**ãæ¡ä»¶ä»ãå¦çã**ãè¡ãã³ãã³ãã§ãããã®ã¾ãã¾ã§ããã ä¸ã®æç« ãã覧ãã
%0 ã«ããããã¡ã¤ã«èªèº«ã®ãã¡ã¤ã«ãã¹ãæ ¼ç´ããã¦ãããã以ä¸ã®æ§ã«è¨è¿°ãããã©ã¤ãã®å¤æ´ããã£ã¬ã¯ããªã®å¤æ´ãè¡ãã %~d0 cd %~d0%~p0追è¨ï¼ id:nanmo ããããã³ã¡ã³ãæ¬ã«ã¦ãã£ã¨çãæ¹æ³ãæãã¦è²°ãã¾ããã cd /d %~dp0cd 㧠/d ã®ãªãã·ã§ã³ãæå®ããã¨é常ããã£ã¬ã¯ããªã®å¤æ´ã ãã§ãã©ã¤ãã®å¤æ´ã¯è¡ã£ã¦ãããªã cd ã³ãã³ãã§ãã©ã¤ãã®å¤æ´ãåæã«è¡ãããã«ãªãã¾ãã ãã¨ãã°ç¾å¨ãDãã©ã¤ãã® d:\test ã«ã㦠Cãã©ã¤ãã® c:\test2 ã«ç§»åãããæ§ãªãã©ã¤ããç°ãªãå ´æã¸ã®ç§»åã以ä¸ã®1è¡ãå®è¡ããã ãã§OKã§ãã cd /d c:\test2ã¡ãªã¿ã«ã³ãã³ãã®ãã«ãã¯ã³ãã³ãããã³ããä¸ã§ãhelp (ã³ãã³ã)ãã¨ã¿ã¤ãããã¨ç¢ºèªã§ãã¾ããcd ã«ã¤ãã¦ç¥ãããå ´å㯠help cd ã§ç¢ºèªã§ãã¾ãã %~dp0 ã¯
ãªãªã¼ã¹ãé害æ å ±ãªã©ã®ãµã¼ãã¹ã®ãç¥ãã
ææ°ã®äººæ°ã¨ã³ããªã¼ã®é ä¿¡
å¦çãå®è¡ä¸ã§ã
j次ã®ããã¯ãã¼ã¯
kåã®ããã¯ãã¼ã¯
lãã¨ã§èªã
eã³ã¡ã³ãä¸è¦§ãéã
oãã¼ã¸ãéã
{{#tags}}- {{label}}
{{/tags}}