[go: up one dir, main page]

Menu

[267579]: / man / fr_FR / prompt.tea  Maximize  Restore  History

Download this file

93 lines (63 with data), 2.9 kB

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
#
# Dos9 Manual pages, The Dos9 project
# Copyright (C) 2012-2018 Romain Garbi (DarkBatcher)
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
{{PROMPT Command and %PROMPT% Variable}}
The {PROMPT} command and the {%PROMPT%} enable changing the
text of the command prompt.
{{Synopsis}}
${PROMPT prompt_format
SET PROMPT=prompt_format}
The {PROMPT} command is equivalent to a call to {set|SET} modifying
the {%PROMPT%} variable. The new format is specified through {prompt_format},
that can be any sequence of characters where the following sub
strings will be expanded:
- {$a} : Expands to {&}.
- {$b} : Expands to {|}.
- {$c} : Expands to {(}.
- {$d} : Expands to the content of {time|%DATE% variable}.
- {$e} : Expands to an escape character (code 27).
- {$f} : Expands to {)}.
- {$g} : Expands to {>}.
- {$h} : Expands to a backspace character.
- {$l} : Expands to {<}.
- {$n} : Expands to current drive (root, if the OS running {dos9|Dos9}
does not provide an equivalent for the windows concept).
- {$p} : Expands to the current working directory.
- {$q} : Expands to {=}.
- {$s} : Expands to a space.
- {$t} : Expands to the content of {time|%TIME% variable}.
- {$u} : Expands to the content of {dos9var|%USERNAME% variable}.
That is, if not modified, the current user name.
- {$w} : Expands to the content of {dos9var|%USERDOMAIN% variable}.
That is, if not modified, the current user domain name.
- {$xCODE;} : Changes locally the color of the text displayed according
to {CODE}, where {CODE} is a code that can be accepted by the
{color|COLOR command}. Changes of color using this method will not affect
the {.} specifiers values. The original color of text is not restored
after displaying the prompt, but you can restore default values using
{$x..;}.
- {$_} : Expands to a new line.
- {$$} : Expands to {$}.
- {$+} : Prints as many {+} as pushed directories inside
the {spec/dirstack|directory stack}.
{PROMPT} without arguments resets {%PROMPT%} variable to its default value.
{{Compatibility}}
Mostly compatible with {cmd.exe}. However, the {$m} specifier is unsupported.
In addition, {$xCODE;} specifier is a {dos9|Dos9} extension.
Available since {218.2}.
{{See also}}
{commands|Commands list}