我改变了的值%PROMPT%
,现在有些事情不起作用。其默认值是什么?
答案1
默认值为$P$G
。
可以special codes
使用以下命令显示prompt /?
:
>prompt /?
Changes the cmd.exe command prompt.
PROMPT [text]
text Specifies a new command prompt.
Prompt can be made up of normal characters and the following special codes:
$A & (Ampersand)
$B | (pipe)
$C ( (Left parenthesis)
$D Current date
$E Escape code (ASCII code 27)
$F ) (Right parenthesis)
$G > (greater-than sign)
$H Backspace (erases previous character)
$L < (less-than sign)
$N Current drive
$P Current drive and path
$Q = (equal sign)
$S (space)
$T Current time
$V Windows version number
$_ Carriage return and linefeed
$$ $ (dollar sign)
If Command Extensions are enabled the PROMPT command supports
the following additional formatting characters:
$+ zero or more plus sign (+) characters depending upon the
depth of the PUSHD directory stack, one character for each
level pushed.
$M Displays the remote name associated with the current drive
letter or the empty string if current drive is not a network
drive.
环境prompt
变量没有出现在您提到的对话框中。我通过 找到了值echo %prompt%
。如果环境变量条目出现,您可能应该删除它,这应该足以恢复为默认值。无论如何,默认情况下它不应该在用户变量中。
我的用户变量仅定义TEMP
和TMP
。