Skip to content

Instantly share code, notes, and snippets.

@Juszczak
Forked from vodrazka/.bash_profile
Created October 17, 2018 15:11
Show Gist options
  • Save Juszczak/318938904e2e9ebea992dcdda14c37d3 to your computer and use it in GitHub Desktop.
Save Juszczak/318938904e2e9ebea992dcdda14c37d3 to your computer and use it in GitHub Desktop.
.bash_profile
export VISUAL=vim
export EDITOR="$VISUAL"
green=$(tput setaf 2)
reset=$(tput sgr0)
PS1="\w \[$green\]$\[$reset\] "
stty -ixon
[ -f /usr/local/etc/bash_completion ] && . /usr/local/etc/bash_completion
test -e "${HOME}/.iterm2_shell_integration.bash" && source "${HOME}/.iterm2_shell_integration.bash"
function iterm2_print_user_vars() {
iterm2_set_user_var gitBranch $((git branch 2> /dev/null) | grep \* | cut -c3-)
iterm2_set_user_var gitBranches $(getBranches)
}
function getBranches() {
while IFS='' read -r line || [[ -n "$line" ]]; do
result="$result\\n$line"
done < ~/.gitbranches
echo $result
}
export PATH="/usr/local/opt/node@8/bin:$PATH"
source ~/.gitbranches
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment