Skip to content

Instantly share code, notes, and snippets.

@bidulock
Last active January 20, 2016 22:40
Show Gist options
  • Save bidulock/5868381 to your computer and use it in GitHub Desktop.
Save bidulock/5868381 to your computer and use it in GitHub Desktop.
My $PS1. 4 lines. Horizontal rule, datetime, pwd, username@host
# This was taken and adapted from some reddit thread with a bunch of prompts.
# check the window size after each command and, if necessary,
# update the values of LINES and COLUMNS.
shopt -s checkwinsize
PS1="\n\$(s=\$(printf '%*s' \$COLUMNS); echo \${s// /―})\n\D{%Y-%m-%d} \t\n"
PS1="$PS1\w\$(__git_ps1)\n"
PS1="$PS1${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]\$ ";
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment