|
|
Command |
Description |
|
|
GETTING STARTED |
|
login-name |
Identifies you to an UNIX system. |
password |
Verifies your identity. |
CTRL/S |
Pauses scrolling. |
CTRL/Q |
Resumes scrolling. |
yppasswd |
Changes your password. |
man -k topic |
Lists commands related to the topic. |
man command |
Displays reference information about |
|
the command. |
logout |
Ends your UNIX session. |
|
|
FILES AND DIRECTORIES |
|
pwd |
Displays the path name of your current |
|
directory. |
mkdir dirname |
Creates a directory. |
mv filename dirname |
Moves files to a different directory. |
mv filename newfilename |
Renames file. |
cd directory |
Moves you to a new working directory. |
cat file |
Displays file on your screen. |
cat > file |
Creates a new file, with input from terminal; |
|
end with CTRL/D. |
cat filename1 filename2 > filename3 |
Concatenates two
files and outputs into a third. |
cat filename1 >> filename2 |
Concatenates files,
appending first to second. |
chmod mode filename |
Changes a file's protection. |
cp filename1 filename |
Copies filename1 to filename2. |
rm filename |
Removes filename. |
rmdir dirname |
Removes dirname. |
|
|
METACHARACTERS |
|
* |
Matches any combination of zero or |
|
more characters. |
? |
Matches any single character. |
|
|
COMMON COMMANDS |
|
alias new old |
Defines new as another name for |
|
command old. |
grep pattern filename |
Returns lines containing pattern from |
|
filename. |
sort filename |
Sorts the input in alphabetic order. |
w |
Returns a list of users logged in. |
finger |
Returns user finger information. |
PIPES AND REDIRECTION |
|
command > filename |
Redirects command output to filename. |
command >> filename |
Appends command output to filename. |
command < filename |
Reads command input from filename. |
command command2 |
Pipes output of command1 to the input |
|
of command2. |
|
|
REPEATING COMMANDS |
|
history |
Lists previous commands. |
!! |
Repeats the previous command. |
!string |
Repeats the previous command that |
|
starts with string. |
!number |
Repeats the command you identify by |
|
number. |
^ wrong^ right |
Corrects errors in the previous |
|
command. |
|
|
CONTROLLING PROCESSES |
|
command & |
Executes command as a background |
|
process. |
ps |
Displays the status of current jobs. |
kill pid |
Terminates the process with process ID |
|
number pid. |
CTRL/Z |
Interrupts the current process. |
fg |
Returns the last interrupted job to |
|
the foreground. |
bg |
Continues the last interrupted job |
|
in the background. |
jobs |
Shows status of background jobs. |
|
|
MAIL - pine |
|
pine |
Starts mail from the shell. |
pine -f folder |
Starts mail and reads the folder you |
|
name, instead of the mailbox folder. |
|
|
TEXT PROCESSING |
|
vi filename |
Starts vi from the shell and edits filename. |
emacs filename |
Starts Gnu emacs from the shell and |
|
edits filename. |