Customize your macOS Terminal Prompt (zsh) — The Easy Way

Short tutorial on how to custom-tailor your mac’s terminal prompt easily.

basic white background and huge prompt
basic white background and huge prompt
$ open .zshrc -t
$ touch .zshrc
PROMPT='%B%U%F{blue}%n%u%b> %f'
export PROMPT
$ source .zshrc
  • the %U…%u underlines the part in between.
  • the %F{color}…%f (or %F{reset}) colors the text in between. The available colors are BLUE, BLACK, CYAN, WHITE, YELLOW, RED and MAGENTA.
  • %n represents the current user
RPROMPT='%F{green}%~%f'
export RPROMPT
$ touch .hushlogin

Writing what I love.