Penguin

Differences between version 5 and predecessor to the previous major change of Aliases.

Other diffs: Previous Revision, Previous Author, or view the Annotated Edit History

Newer page: version 5 Last edited on Monday, November 20, 2006 9:21:22 am by CraigBox Revert
Older page: version 4 Last edited on Sunday, November 19, 2006 5:09:47 pm by BenStaz Revert
@@ -1,32 +1,29 @@
-Can you think of a REALLY long command that you use on a regular basis?  
-Well if so aliases are for you! :D  
+Can you think of a REALLY long command that you use on a regular basis? If so, aliases are for you! 
  
-Basically an alias is a small command or name to execute a long string.  
- They couldn't be easier to make. At your terminal type: 
+An alias is a small command or name to execute a long string. They couldn't be easier to make. At your terminal, type: 
  
-* alias <name>='<command to perform>' 
+<tt> alias <name>='<command to perform>'</tt>  
  
-so if I do:  
-* alias staz='echo you rock Staz'  
- and then type ' staz' at the terminal, I will be told that I rock :)  
-Of course there are much more useful aliases to be made than the one above :P  
+If you type <tt> alias staz='echo you rock Staz'</tt>, and then type <tt> staz</tt> at the terminal, you will be told that Staz rocks.  
+  
+Of course there are much more useful aliases to be made than the one above!  
  
 Take for example: 
-alias apt='sudo nano /etc/apt/sources.list' 
+<tt> alias apt='sudo nano /etc/apt/sources.list'</tt>  
  
 Think about how many times you have edited this file. Wouldn't typing 'apt' be so much nicer? 
 This alias will only last while you have this terminal window open if you want a permanent one, read on :) 
  
 To list the aliases available to you, simply type 'alias'. 
  
 To remove an alias do: 
-*unalias <nameofalias> 
+*<tt> unalias <nameofalias></tt
  
-!UBUNTU  
+!Making aliases permanent  
  
 First we edit your ~~/.bashrc file. 
-*sudo nano ~~/.bashrc 
+*<tt> sudo nano ~~/.bashrc</tt>  
 Now scroll down to find: 
  
 <verbatim> 
 #if [ -f ~/.bash_aliases ]; then 
@@ -36,8 +33,8 @@
  
 Uncomment these three lines (or if they don't exist add them). Now save. 
  
 Now do: 
-*nano ~~/.bash_aliases 
+*<tt> nano ~~/.bash_aliases</tt>  
  
 Add all your aliases (in the same format as above) with each being on a separate line. Save when you are done. 
-Good stuff, now reboot and open a terminal. Hopefully your aliases will work like a charm. 
+Good stuff, now open a new terminal. Hopefully your aliases will work like a charm.