If you don't understand a command you can always use:
man command
- This will display a manual for command
ls
- directory listing
ls al
- formatted listing with hidden files
cd dir
- change directory to dir
cd
- change directory to home directory
pwd
- show current directory
mkdir dir
- create directory dir
rm file
- delete file
rm -r dir
- delete directory
rm -f file
- force remove file
rm -rf dir
- force remove directory dir
cp file1 file2
- copy file1 to file 2
mv file1 file2
- rename file1 to file 2 // Also used to move files to different directories
touch file1
- create or update file1
cat file1
- see the contents of file1
chmod octal file
- change permission of file
order: owner(u)/group(g)/world(o) | all(a)
eg:
chmod 777
- rwx for everyone
chmod 755
- rw for owner, rx for group/world
or:
chmod a+rwx
- rwx for everyone
chmod u+rw
- rw for owner
date
- show current date/time
cal
- show this months's calendar
w
- display who is online
whoami
- who are you logged in as
uname -a
- show kernel configuration
df
- show disk usage
whereis app
- show possible locations of app
which app
- show which app will be run by default
ssh user@host
- connect to host as user
ssh -p port user@host
- connect using port p
ssh -D user@host
- connect and use bind port
ping host
- pong host 'host'
whois domain
- get whois for domain
wget filelink
- download filelink
wget -r url
- recursively download file from url
ctrl + c
- halts current command
ctrl + z
- stops current command
fg
- resume stopped command in foreground
bg
- resume stopped command in background
ctrl + d
- log out of current session
ctrl + w
- erases one word in current line
ctrl + u
- erases whole line
ctrl + r
- reverse lookup of previous commands
!!
- repeat last command
exit
- log out of current session