Microwave Biscuit

Handy Bash Alias

Posted in Linux by microwavebiscuit on February 20, 2007

In my .bashrc file I have the following alias definitions which I find handy. I’ve cribbed many of them from different resources on the net.

alias la='ls -Al' # show hidden files
alias lx='ls -lXB' # sort by extension
alias lk='ls -lSr' # sort by size
alias lc='ls -lcr' # sort by change time
alias lu='ls -lur' # sort by access time
alias lt='ls -ltr' # sort by date
alias lm='ls -al |more' # pipe through 'more'
alias ll='ls -l'
alias l='ls -CF'
alias rm='rm -i' #better safe than sorry
alias mv='mv -i'
alias cp='cp -i'
alias vi='vim'
alias du='du -h'
alias df='df -kh'
alias ps='ps auxf'
alias home='cd ~'
alias pg='ps aux | grep' #requires an argument
alias un='tar -zxvf'
alias mountedinfo='df -hT'
alias ping='ping -c 10'
alias openports='netstat -nape --inet'
alias ns='netstat -alnp --protocol=inet | grep -v CLOSE_WAIT | cut -c-6,21-94 | tail +2'
alias du1='du -h --max-depth=1'
alias da='date "+%Y-%m-%d %A %T %Z"'
alias dos2unix="perl -pi -e 's/\r\n/\n/;'"
alias kate='kate 2>/dev/null &'
alias firefox='firefox 2>/dev/null &'
# spelling typos
alias xs='cd'
alias vf='cd'
alias moer='more'
alias moew='more'
alias kk='ll'
alias exot='exit'

One Response

Subscribe to comments with RSS.

  1. […] 20th, 2007 · No Comments Microwave Biscuit has a handy list of aliases that can be put into your .bashrc file.  I wouldn't use the whole […]

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: