dotfiles/bash/.bashrc

74 lines
1.7 KiB
Bash
Raw Normal View History

2016-09-12 15:52:11 +01:00
export DOTFILES="/home/jake/.dotfiles"
2016-05-06 17:04:10 +01:00
2016-09-12 15:52:11 +01:00
source $DOTFILES/bash/boilerplate.sh
source $DOTFILES/bash/catfish.sh
source $DOTFILES/bash/javascript.sh
2016-07-07 17:38:01 +01:00
# Load Programs
2016-05-06 17:04:10 +01:00
export NVM_DIR="/home/jake/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && . "$NVM_DIR/nvm.sh" # Load on ubuntu
2016-07-23 16:46:44 +01:00
2016-05-06 17:04:10 +01:00
eval $(thefuck --alias)
2016-09-12 15:52:11 +01:00
export PATH="/home/jake/.pyenv/bin:$PATH"
2016-07-23 16:46:44 +01:00
eval "$(pyenv init -)"
eval "$(pyenv virtualenv-init -)"
2016-07-07 17:38:01 +01:00
2016-05-06 17:04:10 +01:00
# Export some variables
export ANDROID_HOME=/opt/android-sdk
2016-07-07 17:38:01 +01:00
# Extend PATH
export PATH=${PATH}:${ANDROID_HOME}/tools
export PATH=${PATH}:${ANDROID_HOME}/platform-tools
2016-05-06 17:04:10 +01:00
export PATH=${PATH}:/opt/genymobile/genymotion
2016-09-12 15:52:11 +01:00
export PATH=/home/jake/.dotfiles/bin:${PATH}
2016-05-06 17:04:10 +01:00
2016-07-07 17:38:01 +01:00
# Export Java home on ubuntu
if [ -f "$(command -v lsb_release)" ]; then
2016-05-06 17:04:10 +01:00
JAVA_HOME=/usr/local/java/jdk1.8.0_73
2016-07-07 17:38:01 +01:00
export PATH=${PATH}:$JAVA_HOME/bin
2016-05-06 17:04:10 +01:00
fi
# bash aliases
alias src="source ~/.bashrc"
2016-07-07 17:38:01 +01:00
alias refresh="cd $PWD > /dev/null"
alias c="clear"
2016-07-23 16:46:44 +01:00
alias yolo="yaourt -Syau"
2016-07-07 17:38:01 +01:00
export EDITOR=/bin/nano
2016-05-06 17:04:10 +01:00
# git aliases
alias gs="git status"
alias gd="git diff"
2016-07-07 17:38:01 +01:00
gh() {
2016-07-23 16:46:44 +01:00
if [ $# -eq 1 ]; then
command git clone git@github.com:RealOrangeOne/${1}
else
command git clone git@github.com:${1}/${2}
fi
2016-07-07 17:38:01 +01:00
}
# Gnome
gd-lock() {
sessionid=`/bin/loginctl list-sessions | grep jake | awk '{print $1}'`
/bin/loginctl lock-session $sessionid
}
gd-unlock() {
sessionid=`/bin/loginctl list-sessions | grep jake | awk '{print $1}'`
/bin/loginctl unlock-session $sessionid
}
alias gdl="gd-lock"
alias gdu="gd-unlock"
2016-05-06 17:04:10 +01:00
# miscellaneous software aliases
alias y="yoga"
alias ym="yoga mode"
2016-09-12 15:52:11 +01:00
alias serve="python2 -m SimpleHTTPServer"
2016-07-23 16:46:44 +01:00
alias make-dotfiles="cd ~/.dotfiles/ && make && cd - > /dev/null"
alias edit-dotfiles="atom ~/.dotfiles/"
2016-09-12 15:52:11 +01:00
alias please="sudo"