=> git.r.bdr.sh
=> summary
=> tree
=> log
=> refs
=> view raw
1 export PATH=/usr/local/bin:/usr/local/sbin:$PATH 2 export NODE_PATH=/usr/local/lib/node_modules:$NODE_PATH 3 4 #Java HOME Adition 5 export JAVA_HOME=$(/usr/libexec/java_home) 6 7 #Amazon Stuff 8 export EC2_HOME=/Users/benbeltran/Documents/code/tools/ec2-api-tools-1.5.2.4 9 export PATH=$PATH:$EC2_HOME/bin 10 export EC2_PRIVATE_KEY=~/.ec2/pk-XBFB3HSRRZAILOFUPE44QAJI5M4Z5TNN.pem 11 export EC2_CERT=~/.ec2/cert-XBFB3HSRRZAILOFUPE44QAJI5M4Z5TNN.pem 12 13 export TERM=screen-256color 14 15 #git function 16 function _set_git_envar_info() { 17 GIT_BRANCH="" 18 GIT_PREFIX="" 19 GIT_STATE="" 20 CHECK_SHIT="lol" 21 RVM_COMMAND=$(rvm-prompt) 22 if [[ $RVM_COMMAND == "" ]] 23 then 24 RVM_COMMAND="system" 25 fi 26 if [[ $(which git 2> /dev/null) ]] 27 then 28 local STATUS 29 STATUS=$(git status 2>/dev/null) 30 if [[ -z $STATUS ]] 31 then 32 return 33 fi 34 GIT_BRANCH="$(git branch --no-color 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/\1/')" 35 if [[ -n "$GIT_BRANCH" ]] 36 then 37 GIT_PREFIX=" on " 38 fi 39 if [[ "$STATUS" == *'working directory clean'* ]] 40 then 41 GIT_STATE="" 42 else 43 GIT_STATE="" 44 if [[ "$STATUS" == *'Changes to be committed:'* ]] 45 then 46 GIT_STATE='!' # Index has files staged for commit 47 fi 48 if [[ "$STATUS" == *'Changed but not updated:'* ]] 49 then 50 GIT_STATE="?" # Working tree has files modified but unstaged 51 fi 52 if [[ "$STATUS" == *'Untracked files:'* ]] 53 then 54 GIT_STATE='?' # Working tree has untracked files 55 fi 56 fi 57 fi 58 } 59 60 export -f _set_git_envar_info 61 62 #this thing for my prompt. 63 export PROMPT_COMMAND="_set_git_envar_info" 64 export PS1='\[\e[0;31m\]\u\[\e[0m\] at \[\e[0;33m\]\h\[\e[0m\] in \[\e[0;32m\]\w\[\e[0m\]$GIT_PREFIX\[\e[1;34m\]$GIT_BRANCH\[\e[0m\]\[\e[0;32m\]$GIT_STATE \[\e[0;33m\]($RVM_COMMAND) \[\e[0m\] \n\$ ' 65 66 #display fortune when I start 67 echo -e "\033[30m" 68 /usr/local/bin/fortune 69 echo -e "\033[m" 70 71 #Editor. 72 export EDITOR="vim" 73 export VISUAL="vim" 74 75 #some aliases. 76 alias dwarffortress="/Applications/Dwarf\ Fortress/df" 77 alias ls="ls -FG" 78 alias rspec="rspec --color" 79 80 #Git utility aliases 81 alias gpsc="git push origin "+$GIT_BRANCH 82 alias gplc="git pull origin "+$GIT_BRANCH 83 84 #Enable Bash Completion 85 if [ -f `brew --prefix`/etc/bash_completion ]; then 86 . `brew --prefix`/etc/bash_completion 87 fi 88 89 #Screeninator and RVM scripts 90 [[ -s $HOME/.rvm/scripts/rvm ]] && source $HOME/.rvm/scripts/rvm 91
text/gemini; charset=utf-8
This content has been proxied by September (ba2dc).