learn
You should be presented with a menu of interactive tutorials available
at Basser. Three of these are basic UNIX tutorials (unix, moreunix, advunix)
which you should go through in your own time.
| Command | What it does | Common Usage | ||||
| passwd | Change your password | passwd | ||||
| ls | List the contents | ls | ||||
| cd | Change working directory | cd <directory> | ||||
| cp | Copy a file | cp <source filename> <target filename> | ||||
| mv | Move/rename a file | mv <source filename> <target filename> | ||||
| netfile | Send a file | netfile <login> <filenames> | ||||
| netget | Get a file sent to you | netget | ||||
| tar | Take several files and put them into one file (similar to zip) |
|
||||
| rm | Remove a file | rm <filenames> | ||||
| mkdir | Make a new directory | mkdir <directory> | ||||
| rmdir | Remove a directory | rmdir <directory> | ||||
| chmod | Change the permissions on a file/directory | chmod <permissions setting> <filename> | ||||
| pwd | Present working directory | pwd | ||||
| man | Get the manual page for a unix command | man <unix command>OR tkman | ||||
| grep | Search for a pattern in a given file | grep <pattern> <filenames> | ||||
| find | Search for a file (in the current working directory and the directories beneath it) | find -name <filename> |
| Character | What it means | Common Usage |
| The working directory (i.e. the directory given by the pwd command) | cp -r ~cs1/lib/html/java/examples/code/lab1/ . | |
| The directory above the working directory | cd .. | |
| Path shortcut | cd ~<login> | |
| Any characters (a wildcard) | ||
| Completes commands/paths (hit twice to see options) | ||
| Path separator |
First, a few useful commands to know when navigating man pages:
| q | Quit |
| Enter key | Go forward one line |
| Space bar | Go forward one page |
| b | Go back one page |
| / | /pattern = Search (forwards) for |
| n | /pattern = Find next occurrence of the pattern |
OR
Use tkman which will give you a GUI view of the man pages
Before reading further, actually bring up the man page for the ls command (using either man or tkman)
A man page is split into sections (some of these may not be present, depending
on the man page):
NAME Summarises what the command does SYNOPSIS How to use the command (syntax) DESCRIPTION A description of the command OPTIONS The options available SEE ALSO The names of related programs EXAMPLES Examples of how to using the command EXIT STATUS
The exit status of the command (useful when writing shell scripts) FILES
A list of files that are used by and/or modified by the command AUTHORS The authors of the program
UNIX tutorials
Note: The full installation of UNIXhelp has not been completed at the present time