Unix Tutorial

If your terminal window hangs after typing a command, use CRTL-C to "escape" out of it!
Go through the Unix Tutorial for Beginners (from the Surrey EE department) and do Tutorials 1-6.
Some differences:
o    In 1.5, the pathname on our machines will look like /home/username (on a Mac it will look like /Users/username/)
o    In 2.1, for the first copying command, do
cp ~jkua/example/ethanol.out  . (Note the dot at the end after the space!)
o    In the rest of this section instead of 'science.txt' it is referring to "ethanol.out"
o    In 2.2, there shouldn't be a dot at the end of the mv command
o    In 2.5, obviously you will have to use strings in the file to successfully search or grep. Interesting strings in the ethanol.out might be "Distance", "Energy", "Angle", "Charge", etc.
o    Skip printer commands in Tutorial 3 for now.

To look up what a command does in Unix, you can always type man command (where command is the Unix command you'd like to know more about).

There are many different text editors. nedit is probably the easiest to use (good for copying columns of data but has certain limitations). I'm very old-fashioned so I use the old Unix program vi. Another common editor used by Unix/Linux people is emacs. Regardless of what text editor you commonly choose, you should learn how to use vi because it is universally found on any computer that can access Xwindows (i.e., pretty much everything). Play around with the text editor until you are comfortable adding or deleting lines, changing text, searching for text, etc. Be sure to visit the Introduction to VI page.

Other things that I use reasonably often:
• To list files with timestamp and details in reverse order, type ls -lrt
• The left mouse button can be used to select and the middle mouse button to paste.
• If you get stuck somewhere and the command line seems to be frozen with a previous command, or if you want to cancel something you're in the middle of typing, use CTRL-C
• When searching for filenames, copying/moving/deleting multiple files, I use the * as a wildcard. Do be very careful before you do something like rm * which removes ALL files in the current directory!

Finally two very useful keyboard shortcuts in Unix:
The up/down arrow keys that allow you to scroll back and forth through previous commands you have typed in. (You can also use the command history to see this.)
The tab key can be used for filename completion. Instead of typing the full name of a file you can press tab at appropriate times to help complete the name.