Skip to content

Instantly share code, notes, and snippets.

@svidgen
Last active March 22, 2025 20:34
Show Gist options
  • Save svidgen/ec825a940ad676cd45577790eddb7796 to your computer and use it in GitHub Desktop.
Save svidgen/ec825a940ad676cd45577790eddb7796 to your computer and use it in GitHub Desktop.
multiline *nix prompt
if [ "$color_prompt" = yes ]; then
# this one should be active. it is ...
# <blue>directory</blue><br /><green>user@host</green>$
PS1='\n\[\033[00;34m\]\w\[\033[00m\]\n${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]\$ '
else
PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ '
fi
unset color_prompt force_color_prompt
# If this is an xterm set the title to user@host:dir
case "$TERM" in
xterm*|rxvt*)
PS1="\[\e]0;${debian_chroot:+($debian_chroot)}\u@\h:\w\a\]$PS1"
;;
*)
;;
esac
# Added by Amplify CLI binary installer
export PATH="$HOME/.amplify/bin:$PATH"
# Enable colors
autoload -U colors && colors
# Subtle text color (light blue or gray)
DIR_COLOR=$'%F{245}' # Try 245 (gray) or 110 (faded blue)
RESET=$'%f' # Reset color
# Prompt definition
PROMPT=$'\n'"${DIR_COLOR}%~${RESET}"$'\n%n@%m %% '
@svidgen
Copy link
Author

svidgen commented Aug 29, 2021

Notably not the entirety of the file.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment