Why is Bash’s Prompt Variable Called PS1 – Command Line Explanation

bashcommand line

The environment variable for the bash prompt is called PS1 (usually set in ~/.bashrc). What does PS1 stand for? Is there a PS2?

Best Answer

PS1 stands for "Prompt String One" or "Prompt Statement One", the first prompt string (that you see at a command line).

Yes, there is a PS2 and more! Please read this article and the Arch wiki and of course The Bash Reference Manual.

Related Question