File Management

University of Wisconsin Madison

Computer Systems Lab CS1000

Wiscinfo
Wiscinfo
CS Home
CS Home
CSL
CSL
Feedback
CS1000
Feedback
Feedback

next up previous contents index
Next: Disk Quotas Up: The File System Previous: Looking at your

File Management

   

The following is a summary of common UNIX commands used for file management. Most of the commands are self-explanatory, yet have more advanced options. See the chapter Getting Ahead for more information, or consult the man pages.

 
cat file1 file2 ...
sends the contents of one or more text files to standard output (usually the screen). Be sure not to cat binary files (executables).  
more file1 ...
displays the contents of a file a screenful at a time. SPACE shows next screenful, b shows previous screenful, RETURN shows next line, ? brings up a help list, and q quits viewing.  
less file1 ...
an enhanced version of more. (Yes, less has more than more.) Extra features include use of arrow keys for scrolling, g goes to beginning of file, G goes to the end, and h brings up a help screen.  
cd path
changes directory to path.
ls [dir]
lists the files of dir or the current directory if no argument is given.  
pwd
prints working directory.  
cp source destination
copies a file.  
mv source destination
moves a file. If both source and destination files have the same path, then this command is equivalent to renaming the file.  
rm file
removes a file.    
mkdir dir
creates a directory of the name dir.    
rmdir dir
removes a directory of the name dir if it is empty.



Caitlin Howell
Thu Jan 16 20:24:40 CST 1997