Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

My Bash aliases don't work

I'm not sure why but my Bash aliases don't seem to work. Here is my .bashrc file

    # v 0.0.1 - 7/03/12

[[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm" # Load RVM into a shell session *as a function*

PATH=$PATH:$HOME/.rvm/bin # Add RVM to PATH for scripting

# expanding history to 10000 commands
export HISTSIZE=10000

# don't store repeated commands more than once
export HISCONTROL=ignoredups

# where to look for Java
export JAVA_HOME=/Library/Java/Home

# tomcat server configuration
export CATALINA_HOME=/usr/local/apache-tomcat-6.0.35

# default editor
export EDITOR=vim

if [ -f ~/.bash_aliases ]; then
    . ~/.bash_aliases
fi

Here is my .bash_aliases file

# v 0.0.1 - 7/03/12

# aliases for directory traversal
alias ..='cd ../'
alias ...='cd ../../'
alias ....='cd ../../../'

alias gs='git status '
alias ga='git add '
alias gb='git branch '
alias gc='git commit'
alias gd='git diff'
alias go='git checkout '
alias gk='gitk --all&'
alias gx='gitx --all'

alias got='git '
alias get='git '
like image 251
steve_gallagher Avatar asked Jul 18 '12 18:07

steve_gallagher


1 Answers

Add this to the end of your .bashrc:

if [ -f $HOME/.bash_aliases ]
then
  . $HOME/.bash_aliases
fi
like image 63
Sean Bright Avatar answered Sep 22 '22 14:09

Sean Bright