Basic Unix commands and the vi editor on the CDF system

This information is useful if you have never used Unix (or Linux) or if you have never used a text editor (such as vi, emacs, pico, etc) under Unix.

Basic Unix

To learn the basic Unix commands, I suggest that you buy the booklet A Student's Guide to CDF, by Jim Clarke, Custom publishing service, UofT bookstore. (This is the same booklet mentioned in the CSC260 course handout.)
You should get familiar with the hierarchical structure of directories under Unix (if you are not already familiar with such a structure) and with the basic Unix commands that manipulate files and directories, such as the following commands:

mkdir dirname (makes a new directory named dirname under the current one)
cd    dirname (changes to directory dirname
               the current directory has the "nickname" . -dot-
               while the parent directory the nickname .. -dotdot-)
rmdir dirname (removes the directory dirname - can't recover it)
ls            (gives a list of files in the current directory)
pwd           (prints the name of the current -working- directory)
cp    filename1 filename2 (copies file filename1 to file filename2)
mv    filename1 filename2 (renames (moves) file filename1 to file filename2)
mv    dirname1  dirname2  (renames directory dirname1 to directory dirname2)
rm    filename (removes file filename - can't recover it)
more  filename (displays the file filename on the screen
               - use < space > or < return > to proceed, use q to quit)
man   command  (displays the Unix manual page for the respective command)
man -k string  (displays all Unix commands that include string
                you can then do man on individual commands)
The above commands are typed by you after the Unix prompt (which is often a % or a :) and are followed by < return > (or < newline > ).
To refer to subdirectories or files several levels down the hierarchy of files and subdirectories, you use / (slash) in Unix (and not \ (backslash) as in DOS or Windows).
You should also get familiar with the use of the special characters that stop or kill a certain Unix command, such as:
control-Z (stops the current command execution, resume by typing bg < return > )
control-C (stops and kills the current command execution)

Vi - a text editor

You should also learn how to use a text file editor, such as vi. (CDF has several text editors already installed; vi is the most commonly used Unix editor.) The directory /u/cssu/pub/doc/vi on the CDF system has a lot of information about how to use vi. To simplify matters, I have copied some of the information so that you can download it through this web page.

The first step is to run the vi tutorial. To do this, log on CDF (e.g. on redwolf.cdf.toronto.edu) and run the command

/u/cssu/pub/doc/vi/vitutor
This will teach you the basic vi commands and make you practice them on the spot. Alternatively, you can study the vi tutorial, then run the above command to practice the basic vi commands.

After running the vi tutorial and being familiar with the basic vi commands, you can refer to other sources for vi:

Maple and MATLAB

CDF has both Maple and MATLAB installed. You do not need to buy anything. For Maple, run

maple
on redwolf.cdf.toronto.edu or
xmaple
on any workstation with X windows.

For MATLAB, run

matlab -nodesktop
or
matlab