A few simple Unix hints

For these practicals, we use a Unix machine, either goss.eng.abdn.ac.uk or hex.eng.abdn.ac.uk. Log in using your Engineering department username and password, using Exceed from one of the classroom computers.

You will now have a Unix terminal window on your computer. You donít need much knowledge of Unix to complete this course, so donít panic.

Some elementary Unix commands are listed below, the command itself is shown in bold, while the arguments (if any) are shown in italics:

mkdir dir
"make directory" ñ it is strongly recommended that you create a special directory for this course

cd dir
"change directory". You can use "cd .." to change to the directory directly below the one you are currently in

rmdir dir
"remove directory"

pwd
"print working directory", shows which directory youíre in

ls
"list files", this provides a short listing, ls ñl is normally better, since it will show you the file sizes as well as modification dates and times.

cp file1 file2
"copy file", copies file1 to file2

mv file1 file2
"move file", moves or renames file1 to file2

rm file
"remove file", deletes file

man command
"manual", provides a (long) manual entry for any Unix command.

The recommended editor for this course is dtpad or nedit, which are menudriven and easy to use. The C compiler is started by the command cc sourcefile.c.

A useful hint when starting the editor is to type a "&" after the command (e.g. "nedit file1.c &"), this will let you use your terminal window for other commands without leaving the editor.


Helge Nareid <h.nareid@eng.abdn.ac.uk>

Back to main page