Unix How-To: Time-Saving Aliases


This alias lets you type "up" when you want to go up one level in the file system -- a 60% reduction in typing over the standard "cd ..".

alias up="cd .."

And for anyone who frequently logs into other systems, especially if they need to switch usernames in the process, aliases like this (one for each target system) can save them a little time and annoyance.

alias server_name='ssh -l myself'

If you use a bunch of aliases and want to see how a particular alias is defined, you can get a listing with the alias command itself. Just type alias followed by the name of the particular alias.

$ alias up
alias up='cd ..'

If you sell your users on a nice collection of aliases, you might also want to tell them how to turn them off when they don't want the particular behavior.

unalias ls

Sometimes you can make a Unix user happy just by giving him a tool that saves him a little time. Sometimes the time you save may be your own. But good use of aliases can always make a day's work feel a little less tedious.

Join us:






IT ManagementWhite Papers & Webcasts

White Paper

ACM Leadership Guide

Webcast On Demand

Data Breaches - Don't Be a Headline

Sponsor: Absolute Software Corporation

See more White Papers | Webcasts

Ask a Question