Formatting for the Prompt Variable
tcsh provides a list of substitutions that can be used in formatting the prompt. The list of available substitutions includes:
|
|
Literal |
|
|
The present working directory. |
|
|
The present working directory, in ~ notation. |
|
|
|
|
|
Previous command’s exit status. |
|
|
The value of the shell or environment variable var. |
|
|
Include string as a literal escape sequence to change terminal attributes (but should not move the cursor location); cannot be the last sequence in the prompt. |
|
|
Parse c as in
the |
|
|
End boldfacing. |
|
|
Begin boldfacing. |
|
|
The last n
(default 1) components of the present working directory; if
a leading |
|
|
Similar to |
|
|
Day of the week (e.g., |
|
|
Day of month (e.g., 09, 10). |
|
|
Number of current history event. |
|
|
The number of jobs. |
|
|
Current tty. |
|
|
Clear from the end of the prompt to the end of the display or the line. |
|
|
First component of hostname. |
|
|
Fully qualified hostname. |
|
|
Username. |
|
|
Current time, with seconds (12-hour mode). |
|
|
Current time, with seconds (24-hour format). |
|
|
In |
|
|
End standout mode (reverse video). ... |
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access