Using the Prompt Command
The Prompt command changes the command line prompt. For example, instead of the usual drive
letter, directory, and greater than sign, you could use the time and date as a prompt. In fact, the
prompt can contain any text you want. To change the prompt, simply type Prompt, followed by the
text you want to display, and press Enter. The following list defines the special characters you can
use as part of the command prompt.
$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 = (Equals sign)
$S (Space)
$T Current time
CREATING BATCH FILES 147
$V Windows version number
$_ Carriage return and linefeed
$$ $ (Dollar sign)
You can access two additional formatting characters when you have command extensions
enabled. The following list describes these two additions.
$+ Displays zero or more plus sign characters depending on the depth of the PushD utility
directory stack. The display shows one character for each level you??™ve pushed onto the stack.
Pages:
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395