Last active
December 4, 2016 09:25
-
-
Save khushmeeet/758aadf58862489622c4d482445fd14b to your computer and use it in GitHub Desktop.
.bash_profile for my Mac
This file contains 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 LC_ALL=en_US.UTF-8 | |
export LANG=en_US.UTF-8 | |
export NVM_DIR="/Users/khushmeetsingh/.nvm" | |
[ -s "$NVM_DIR/nvm.sh" ] && . "$NVM_DIR/nvm.sh" # This loads nvm | |
# added by Anaconda3 4.1.1 installer | |
export PATH="/Users/khushmeetsingh/anaconda/bin:$PATH" | |
export CLASSPATH=".:/usr/local/lib/antlr-4.5.3-complete.jar:$CLASSPATH" | |
export PATH=${PATH}:/usr/local/mysql/bin | |
# showing git branch in prompt | |
parse_git_branch() { | |
git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/ (\1)/' | |
} | |
# Enabling Font Colors and Showing Git Branch | |
export PS1="\[\033[33;1m\]\w\[\033[32m\]\$(parse_git_branch)\[\033[m\]\$ " | |
export CLICOLOR=1 | |
export LSCOLORS= gxBxhxDxfxhxhxhxhxcxcx | |
# Enabling Git Autocompletation | |
if [ -f $(brew --prefix)/etc/bash_completion ]; then | |
. $(brew --prefix)/etc/bash_completion | |
fi | |
# Adding Git Alias | |
alias ga='git add' | |
alias gp='git push' | |
alias gl='git log' | |
alias gs='git status' | |
alias gd='git diff' | |
alias gm='git commit -m' | |
alias gma='git commit -am' | |
alias gb='git branch' | |
alias gc='git checkout' | |
alias gra='git remote add' | |
alias grr='git remote rm' | |
alias gpu='git pull' | |
alias gcl='git clone' | |
alias gclean='git clean -fd && git checkout .' | |
alias gh='git push heroku' | |
alias jp='jupyter notebook' | |
# Adding Power Off Alias | |
alias off='sudo /sbin/shutdown -h now' | |
alias sleep='pmset sleepnow' | |
alias lock='/System/Library/CoreServices/"Menu Extras"/User.menu/Contents/Resources/CGSession -suspend' | |
# Adding Edit Alias | |
alias edit='SUDO_EDITOR="open -FWne" sudo -e' | |
alias editb='open -e ~/.bash_profile' | |
alias edith='edit /etc/hosts' | |
alias edithp='nano ~/.hyperterm.js' | |
alias antlr4='java -jar /usr/local/lib/antlr-4.5.3-complete.jar' | |
alias grun='java org.antlr.v4.gui.TestRig' | |
# Adding Reload Alias | |
alias reload='. ~/.bash_profile' | |
# Adding Shortcuts Alias | |
alias ll='ls -lh' | |
alias la='ls -lhA' | |
alias l='ls' | |
alias c='clear' | |
alias q='exit' | |
alias rm='rm -i' | |
alias rmd='rmdir -i' | |
alias m=‘mkdir’ | |
alias ..='cd ..' | |
alias .='cd' | |
alias sc='cd ~/SOURCE\ CODE/' | |
# Hera Server | |
hera(){ | |
cd ~/SOURCE\ CODE/hera/client | |
npm start | |
} | |
# Python Server | |
py-server(){ | |
python -m SimpleHTTPServer 8000 | |
} | |
#THIS MUST BE AT THE END OF THE FILE FOR SDKMAN TO WORK!!! | |
export SDKMAN_DIR="/Users/khushmeetsingh/.sdkman" | |
[[ -s "/Users/khushmeetsingh/.sdkman/bin/sdkman-init.sh" ]] && source "/Users/khushmeetsingh/.sdkman/bin/sdkman-init.sh" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment