Created
August 18, 2017 16:17
-
-
Save ruslanxdev/24d21cbc944873ff84d4e7692cfa7a39 to your computer and use it in GitHub Desktop.
My .bash_profile.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| export PATH=/usr/local/bin:/usr/local/sbin:$PATH | |
| export NVM_DIR="$HOME/.nvm" | |
| . "/usr/local/opt/nvm/nvm.sh" | |
| export PATH="$HOME/.rbenv/bin:$PATH" | |
| eval "$(rbenv init -)" | |
| if [ -f $(brew --prefix)/etc/bash_completion ]; then | |
| . $(brew --prefix)/etc/bash_completion | |
| fi | |
| function git_branch { | |
| git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/\* \1/' | |
| } | |
| function prompt { | |
| local BLACK="\[\033[0;30m\]" | |
| local RED="\[\033[0;31m\]" | |
| local GREEN="\[\033[0;32m\]" | |
| local YELLOW="\[\033[0;33m\]" | |
| local BLUE="\[\033[0;34m\]" | |
| local PURPLE="\[\033[0;35m\]" | |
| local CYAN="\[\033[0;36m\]" | |
| local WHITE="\[\033[0;37m\]" | |
| local RESETCOLOR="\[\e[00m\]" | |
| export PS1="$BLUE\u$RESETCOLOR: \w $GREEN\$(git_branch)\n$YELLOW\$ " | |
| trap 'tput sgr0' DEBUG | |
| } | |
| prompt |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment