This is an old revision of the document!
UNIX Command Reference
The command prompt in UNIX is called the shell. Here is a list of common UNIX commands which will work across many different versions of UNIX with discrepancies in Example/Notes.
Command | Description | Examples | Notes | ||||
as | ASsembler | as input.s | |||||
cc | C Compiler | cc input.c | Creates an executable named a.out by default | ||||
cd | Change working Directory | cd tmp | on Version 6 this command is chdir | ||||
df | Disk Free | df | Displays summary of free disk space. May take time to complete on some systems | ||||
ed | EDitor | ed filename | ED is the standard (line) text editor | ||||
echo | Echo | echo ${HOME} | Prints the value assigned to the variable HOME | ||||
env | ENVironment settings | env | Displays the shell environment settings (see set)) | ||||
ld | Link Loader | ld inputfile | |||||
ls | LiSt directory | ls -l | provides a long LiSting | ||||
man | MANual | man man | On some systems, displays online manual pages. See also apropos | ||||
ps | Process Status | ps -a or ps -l | prints All or Long Process Status | ||||
pwd | Present Working Directory | pwd | Prints the working directory | ||||
set | SET or display shell parameters | set | Sets or displays the shell environment settings (see env) | ||||
vi | VIsual editor | vi filename | vi is a screen editor |
On some systems typing games will print a list of games.
directory | description | ||
/ | This is the top level or root directory | ||
/bin | common user programs are here (type echo ${PATH} to see more | ||
/etc | This is the system directory | ||
/lib | System library files | ||
/usr | “Unix System Resources” or “USeR” directory, depending on who you ask - contains additional binaries, libraries, manpages | ||
/usr/games or /usr/local/games | Usually contains the standard UNIX games |