Docsity

UNIX Commands Quick Reference, Study notes of Computer Science

Toggle sidebar
bg1
UNIX Commands Quick Reference
-1-
Command Description Examples
nispasswd change your password
date displays date and time
who displays current users logged on
talk talk/chat with another logged talk jones
on user
mesg n disable incoming messages
cal displays monthly calendar cal 2000
cal 2 2000
cat display the contents of a file cat prog1.cc
more display the contents of a file
with pauses more prog1.cc
mv rename file mv prog1.cc prog1new.cc
rm delete file rm prog*.cc
will prompt for confirmation
no prompt rm -f prog*.cc
cp copy the contents of a file cp prog1.cc prog1old.cc
prompt on overwrite cp -i prog1.cc prog1old.cc
cat concatenate two or more files cat file1 file2 > file3
lpr print file lpr -Ppost10 prog1.cc
lpq check print queque lpq -Ppost10
lprm remove print job from queue lprm -Ppost10 768
pf2

Partial preview of the text

Download UNIX Commands Quick Reference and more Study notes Computer Science in PDF only on Docsity!

UNIX Commands Quick Reference

Command Description Examples nispasswd change your password date displays date and time who displays current users logged on talk talk/chat with another logged talk jones on user mesg n disable incoming messages cal displays monthly calendar cal 2000 cal 2 2000 cat display the contents of a file cat prog1.cc more display the contents of a file with pauses more prog1.cc mv rename file mv prog1.cc prog1new.cc rm delete file rm prog.cc will prompt for confirmation no prompt rm -f prog.cc cp copy the contents of a file cp prog1.cc prog1old.cc prompt on overwrite cp -i prog1.cc prog1old.cc cat concatenate two or more files cat file1 file2 > file lpr print file lpr -Ppost10 prog1.cc lpq check print queque lpq -Ppost lprm remove print job from queue lprm -Ppost10 768

UNIX Commands Quick Reference

Command Description Examples diff compare two files diff prog1.cc prog1old.cc -w ignore blanks -i ignores case ls display a listing of files within the current directory -a include. files as well -l include protection levels mkdir create directory mkdir cs cd change working directory cd cs cd .. up one level cd back to root level rmdir deletes an empty directory rmdir cs rm -r deletes all files and directory rm -r cs210old will prompt before deleting files -f no prompt

chmod sets file protection level chmod a+rx prog1.cc a+rxw all can read, write execute a-rxw remove all's read, write,execute

quota -v display disk quota and usage

man help pages man cat