在 Linux 终端中表示新命令行的东西叫什么,我可以自定义它吗?
What do I call the thing that signifies a new command line in the Linux terminal and can I customize it?
我已经习惯了 Linux(对它很陌生),我想知道我是否可以做些什么来自定义 root@kali:-# 部分(我知道这表示我在哪里在我的电脑上)但我想更改颜色和显示格式!
谁能帮帮我?
它被称为 "prompt",它由 PS1
shell 变量控制。
参考文献:
- Bash manual
- POSIX sh Shell Variables
- Bash Prompt HOWTO
- ps1 Stack Overflow 上的标签
我已经习惯了 Linux(对它很陌生),我想知道我是否可以做些什么来自定义 root@kali:-# 部分(我知道这表示我在哪里在我的电脑上)但我想更改颜色和显示格式!
谁能帮帮我?
它被称为 "prompt",它由 PS1
shell 变量控制。
参考文献:
- Bash manual
- POSIX sh Shell Variables
- Bash Prompt HOWTO
- ps1 Stack Overflow 上的标签