From e1fe075a8bdb9396826e369d8ac3e2db0a834daa Mon Sep 17 00:00:00 2001 From: Paul Trowbridge Date: Fri, 19 Jun 2020 00:20:10 -0400 Subject: [PATCH] add usage of powerline-go, needs to be installed from 'o get -u github.com/justjanne/powerline-go' --- .bashrc | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/.bashrc b/.bashrc index 043c099..4fdea88 100644 --- a/.bashrc +++ b/.bashrc @@ -120,6 +120,16 @@ EDITOR=/usr/bin/vim.basic PAGER="less" LESS="-S" export IPTOKEN="6ac0a563fc06ab" -export PG="psql -U ptrowbridge -d ubm -p 5030 -h usmidlnx01" +export PG="psql -U ptrowbridge -d ubm -p 5432 -h 192.168.1.110" export NVM_DIR="/home/pt/.nvm" [ -s "$NVM_DIR/nvm.sh" ] && . "$NVM_DIR/nvm.sh" # This loads nvm + + +GOPATH=$HOME/go +function _update_ps1() { + PS1="$($GOPATH/bin/powerline-go -error $?)" +} +if [ "$TERM" != "linux" ] && [ -f "$GOPATH/bin/powerline-go" ]; then + PROMPT_COMMAND="_update_ps1; $PROMPT_COMMAND" +fi +