Commands grouped by category. Each command shows an example and expected output.
ls -l
-rw-r--r-- 1 user user 120 Sep 15 file.txt
drwxr-xr-x 2 user user 4096 Sep 15 docspwd
/home/usercd /var/log
pwd
/var/logmkdir projects
ls
projectsrmdir projects
ls
(no projects directory shown)touch notes.txt
ls
notes.txtcp notes.txt backup.txt
ls
backup.txt notes.txtmv backup.txt archive.txt
ls
archive.txt notes.txtrm archive.txt
ls
notes.txttree
.
├── docs
│ └── report.txt
└── notes.txtcat notes.txt
This is a note.less /etc/passwd
root:x:0:0:root:/root:/bin/bash
...
(Press q to quit)head /etc/passwdtail /etc/passwdnano notes.txt
(Opens interactive editor)chmod 644 notes.txt
ls -l notes.txt
-rw-r--r-- 1 user user 15 Sep 15 notes.txtsudo chown root notes.txt
ls -l notes.txt
-rw-r--r-- 1 root user 15 Sep 15 notes.txtumask
0022find . -name "*.txt"
./notes.txtlocate passwd
/etc/passwd
/usr/share/doc/passwdgrep root /etc/passwd
root:x:0:0:root:/root:/bin/bashwc notes.txt
1 4 15 notes.txtsort names.txtuniq names.txttar -cvf backup.tar notes.txtgzip notes.txt
ls
notes.txt.gzgunzip notes.txt.gzzip archive.zip notes.txtunzip archive.zipps aux | head -5tophtopkill 1234jobsbg %1fg %1ping -c 2 google.comcurl https://example.comwget https://example.com/file.txtip addrss -tulnscp notes.txt user@192.168.1.10:/home/user/ssh user@192.168.1.10uname -adf -hdu -sh /var/logfree -huptimewhohistory | tail -5