Originally posted by jbsnake
Code:
# I use this so that I always have my directories and files color coded
# This is usually already in some of your more user friendly versions of linux
alias ls='ls --color=auto'
# This one does four things for me
# First - it saves the directory I'm currently working in
# Second - it mounts my floppy drive
# Third - changes to the directory that it mounted the drive to
# Fourth - it lists the directory's contents
alias floppy='FDIR=`pwd`;mount /mnt/fl;cd /mnt/fl;ls'
# This one does the reverse
# First - it changes to the directory it stored while mounting the floppy
# Second - it unmounts the drive
alias xfloppy='cd $FDIR;umount /mnt/fl'
# This one does the same thing as the floppy mount, except it's for my cdrom
alias cdrom='CDIR=`pwd`;mount /mnt/cd;cd /mnt/cd;ls'
# This one does the same thing as the floppy unmount, except
# It ejects the cdrom once unmounted
alias xcdrom='cd $CDIR;umount /mnt/cd;eject'
# This set is for the usb jump drive I have
# Does the same as the floppy mount/unmount
alias usb='UDIR=`pwd`;mount /mnt/usb;cd /mnt/usb;ls'
alias xusb='cd $UDIR;umount /mnt/usb'
# This one is to keep my pacman mirrors sorted for speed :)
# Gotta love archlinux
alias resort_pacman='sortmirrors.pl </etc/pacman.conf >pacman.conf.new'
Originally posted by CrouseHow about
Code:
alias rd='rm -rf'
Originally posted by jbsnakeheh....i never use rmdir...just
Code:
rm -Rf <directory name>
ofcourse there is also
Code:
alias shutdown='sudo shutdown'
alias l='ls -l'
alias la='ls -la'
my most loved
Code:
alias scripts='cd /home/jbsnake/scripts'
Originally posted by isacklowok, here a few of my favorites
i have quite a few that are just shortcuts quickly ssh into my many servers. i have the same admin account on all my systems so i just setup an ssh-key with a blank password so i can quickly log in
Code:
alias <servername>="ssh <server>"
i always thought this should be the default view for lsmod
Code:
alias lsmod="lsmod | sort"
a quick shortcut when printing from the cli
Code:
alias print="/usr/bin/lpr-cups"
this one is one of my more heavily used ones. i use it to check for open ssh connections before i logout everynight. "$ psgrep ssh"
Code:
alias psgrep="ps -aux | grep -v grep | grep"
these 2 make sure i don't do something stupid when i am housecleaning
Code:
alias cp="cp -i"
alias mv="mv -i"
the next few are just to save me a few keystrokes
Code:
alias df="date&&df -h"
alias du="du -c -s -h"
alias grep="grep -r -i"
alias su="su -l"
alias ifconfig="/sbin/ifconfig"
this one is because i am just lazy

Code:
alias x="startx"
this one is on a specific server that has some very long mount paths. it just cleans up the output a bit
Code:
alias df="date&&df -h | grep -v iso | grep -v 10[.]11[.]12[.]253"
these are some new ones that i just haven't setup into a script yet. the first one mounts port 25/smtp from my mail server to my laptop so i don't need to run sendmail for smtp and i can always send mail no matter where i am and what isp i am on. i just set my mail app to use "localhost" for the smtp server. the second one allows me to easily connect to remote ipp/cups printers at my house and a private network while i am out and about. since i am the only one with shell access to all my systems i don't see the point in installing sudo to get root access. the user is needed in the ssh commands since i don't allow root to login via ssh.
Code:
alias smtp="su -c 'ssh -L 25:localhost:25 user@host -N -f'"
alias cups_home="su -c 'etc/rc.d/rc.cups stop&&ssh -L 631:localhost:631 user@host -N -f'"