Cheatsheets of linux commands & Tutorials to help begginers navigate
Show Current Path:
pwd
Change Directory:
cd <new directory>
list files:
ls
Include hidden files
ls -a
List ownership:
ls -l
These can be combined
ls -la
or
ls -al
Create a new Directory:
mkdir <directory name>
To move or rename Directory:
mv <source_directory> <target_directory>
To Delete a Directory
For an empty directory:
rmdir <directory>
For a directory that is not empty: use rm with recursive (-r) flag
rm -r
What exactly is PATH, why is PATH and how can PATH improve your life?
https://linuxize.com/post/how-to-add-directory-to-path-in-linux/
to add /bin
in home directory to path PER USER
nano ~/.bashrc
~/.bashrc
export PATH="$HOME/bin:$PATH"
Global shell specific configuration files such as /etc/environment and /etc/profile. Use this file if you want the new directory to be added to ALL system USERS $PATH.
Scan IPs on Network XX.XX.XX
sudo nmap XX.XX.XX.* -rP
- Note. Dont know what flags do but -rP seems useful
-rP
Dont know but lots of info - no device type
-sP
Reports back device types
arp -a
Syntax:
scp <source> <destination>
To copy a file from B to A while logged into B:
scp /path/to/file username@a:/path/to/destination
To copy a file from B to A while logged into A:
scp username@b:/path/to/file /path/to/destination