Command Line
Scanning network for ip addresees
This does a simple ping scan in the entire subnet to see which hosts │ are online.
Install nmap
nmap
or more commonly
Cleaning and clearing logfiles
journal
Clearing out logs older than 10 days
Clearing out journal more than 2 gigs
Any log files
Get sizes
Clear logs that are huge
Setting up webservers
See web_servers.md
diff
files in vim
diff
files in vimdiff
online files in vim
curl
curl
See curl.md
Showing Key Codes
Find text in a file
f
= file
Encrypt and Decrypt
Encrypt: EASIEST OPTION
Alternative method:
Decrypt:
Alternative Method: add -d
to the above command
Adding to $PATH
Simply add /place/with/the/file
to the $PATH
variable with the following command:
Finding directories over/under a certain size
This shows directories larger than 1 gig
Star Wars Asciimation
Umcompress & Compress
7zip
Unzip zip file
List files in archive
For tar.gz
To unpack a tar.gz file, you can use the tar command from the shell. Here's an example:
The result will be a new directory containing the files.
For just .gz (.gzip)
In some cases the file is just a gzip format, not tar. Then you can use:
Command Line Notes
September 3,2019
zsh CTRL + R lets you search through recent commands
History Example git
and ⇧ goes through all git
command history
Last updated