gpt4 book ai didi

command-line - cmd/C 是什么意思?

转载 作者:行者123 更新时间:2023-12-03 04:09:49 26 4
gpt4 key购买 nike

我能理解cmd但不是cmd /c 。我试图从当前使用Runtime.getRuntime().exec("cmd /C java helloworld");调用一个java程序这引起了我的疑问。

最佳答案

您应该感兴趣的部分是 /? 部分,它应该可以解决您使用该工具遇到的大多数其他问题。

Microsoft Windows XP [Version 5.1.2600](C) Copyright 1985-2001 Microsoft Corp.C:\>cmd /?Starts a new instance of the Windows XP command interpreterCMD [/A | /U] [/Q] [/D] [/E:ON | /E:OFF] [/F:ON | /F:OFF] [/V:ON | /V:OFF]    [[/S] [/C | /K] string]/C      Carries out the command specified by string and then terminates/K      Carries out the command specified by string but remains/S      Modifies the treatment of string after /C or /K (see below)/Q      Turns echo off/D      Disable execution of AutoRun commands from registry (see below)/A      Causes the output of internal commands to a pipe or file to be ANSI/U      Causes the output of internal commands to a pipe or file to be        Unicode/T:fg   Sets the foreground/background colors (see COLOR /? for more info)/E:ON   Enable command extensions (see below)/E:OFF  Disable command extensions (see below)/F:ON   Enable file and directory name completion characters (see below)/F:OFF  Disable file and directory name completion characters (see below)/V:ON   Enable delayed environment variable expansion using ! as the        delimiter. For example, /V:ON would allow !var! to expand the        variable var at execution time.  The var syntax expands variables        at input time, which is quite a different thing when inside of a FOR        loop./V:OFF  Disable delayed environment expansion.

关于command-line - cmd/C 是什么意思?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/515309/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com