https://regex101.com/ https://regexr.com/
abc… Letters
123… Digits
\d Any Digit
\D Any Non-digit character
. Any Character
\. Period
[abc] Only a, b, or c
https://regex101.com/ https://regexr.com/
abc… Letters
123… Digits
\d Any Digit
\D Any Non-digit character
. Any Character
\. Period
[abc] Only a, b, or c
gcloud version | |
gcloud components list | |
gcloud components update | |
gcloud compute instances list --filter user | |
gcloud compute scp --recurse user@user-slowhttptest:/home/user/httpbin.csv.html ~/Desktop | |
gcloud auth list | |
gcloud config list account | |
https://iterm2.com/documentation-utilities.html | |
# Displays the image inline. | |
imgcat filename | |
# Shows a directory listing with image thumbnails | |
imgls | |
# Checks if the terminal is iTerm2 | |
it2check |
## Validate Bind file | |
named-checkzone example.com example.com.zone | |
# Get DNSKEY (KSK & ZSK) | |
dig example.com +rrcomments -t DNSKEY | |
# Test DNSSEC resolution | |
delv www.example.com +multi +vtrace | |
# Get DNSKEY in bulk | |
dig -f zones.txt +noall +answer -t dnskey @1.1.1.1 > dnskey.txt |
sudo snap install certbot-dns-cloudflare | |
sudo certbot certonly \ | |
--dns-cloudflare \ | |
--dns-cloudflare-credentials ~/cloudflare.ini \ | |
--dns-cloudflare-propagation-seconds=300 \ | |
-d chriswang.me -d "*.example.com" |
## MTR on TCPO:80 | |
sudo mtr -zrntwP 80 www.example.com |
ab -k -n 1000 -c 5 -g output.tsv -H "x-test: RL" http://www.example.com/status/200 | |
ab -n 10000 -c 5 https://www.example.com |
## To hard reset a single file to HEAD: | |
git checkout @ -- myfile.ext | |
## Unstage an added file in Git | |
git reset HEAD path/to/file | |
## Check staged differences | |
git diff --cached |
# [MP4] Inspect Atomic structure | |
AtomicParsley --version | |
AtomicParsley example.mp4 -T 1 | |
# Ubuntu | |
# Add users | |
sudo adduser newuser | |
# Delete users | |
sudo deluser newuser | |
# Show users | |
less /etc/passwd | |
getent passwd |