Difference between revisions of "Tip 17: Aliases"
From Vlsiwiki
(Created page with 'Aliases are effectively user-created command-line shortcuts. In Ubuntu, several aliases are already created to make life on the command line a little more attractive. To see what…') |
|||
Line 7: | Line 7: | ||
To add more aliases, we can type something like | To add more aliases, we can type something like | ||
− | <nowiki>alias svnclean="svn st | sed "/^M/d" | sed "^/A/d" | sed "s/\?[[:space:]]*//" | xargs rm -r"</nowiki> | + | <nowiki>alias svnclean="svn st | sed "/^M/d" | sed "^/A/d" | sed "s/\?[[:space:]]*//" | xargs rm -r"</nowiki> See: [[Tip 16: Cleaning up an SVN directory]] |
By default, Ubuntu also reads in a file in your home directory called .bash_aliases | By default, Ubuntu also reads in a file in your home directory called .bash_aliases | ||
Simply add the line as above to that file and it will create the alias every time you start a new terminal window. | Simply add the line as above to that file and it will create the alias every time you start a new terminal window. |
Revision as of 18:57, 7 July 2011
Aliases are effectively user-created command-line shortcuts. In Ubuntu, several aliases are already created to make life on the command line a little more attractive. To see what's already there, simply type:
$alias
To add more aliases, we can type something like
alias svnclean="svn st | sed "/^M/d" | sed "^/A/d" | sed "s/\?[[:space:]]*//" | xargs rm -r" See: Tip 16: Cleaning up an SVN directory
By default, Ubuntu also reads in a file in your home directory called .bash_aliases Simply add the line as above to that file and it will create the alias every time you start a new terminal window.