Utilities

Useful ideas

Special characters

& ; | * ? ' " ` [ ] ( ) $ < > { } # / \ ! ~

Quoting special characters

$ echo '$PATH'
$PATH
$ echo "$PATH"
/usr/sbin:/usr/bin:/sbin:/bin
$ echo \$PATH
$PATH

Very useful utilities

ls

ls

cat

rm

less (another pager along the lines of more and pg)

less, continued

Working with files

cp

mv

lpr

a2ps

grep/egrep/fgrep

tail

sort

uniq

diff

file

pipes

Four more utilities

echo

date

$ date --iso-8601
2016-01-28
$ date '+%A'
Tuesday

date

script

dos2unix, unix2dos

Compression and archiving

xz

xzcat, unxz

bzip2

bunzip2 and bzcat

gzip, zcat, gunzip

tar

User and system information

top and htop

w, who, last

$ w
 10:52:34 up 40 min,  3 users,  load average:
USER     TTY      FROM             LOGIN@
langley  tty8     :0               10:12 
$ who
langley  tty8         2015-09-08 10:12 (:0)

uptime

$ uptime
 10:53:20 up 40 min,  3 users,  load average:

free

$ free -h
             total       used       free   
Mem:           15G       3.3G        12G   
-/+ buffers/cache:       1.8G        13G
Swap:          59G         0B        59G

write

mesg