Skip to content

Instantly share code, notes, and snippets.

@tukkek
Last active October 8, 2025 13:01
Show Gist options
  • Select an option

  • Save tukkek/167b0a7f562bfd643a5929ed99e7d5e4 to your computer and use it in GitHub Desktop.

Select an option

Save tukkek/167b0a7f562bfd643a5929ed99e7d5e4 to your computer and use it in GitHub Desktop.
Minimalist BASH command-prompt.

Minimalist command-prompt for .bashrc-compatible terminals. Good for a clean-look or enabling more; smaller terminal-windows!

PS1_COLOR="\[$(tput bold)\]"
PS1_RESET="\[$(tput sgr0)\]"
PS1_STYLE=" ${PS1_COLOR}\W${PS1_RESET} "
# all terminals
PS1="$PS1_STYLE"
# some terminals
if [[ "$TERM_PROGRAM" == "vscode" ]]; then PS1="$PS1_STYLE"; fi

Example display:

~ cd /var/

var cd /var/log/

log _

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