Useful commands
Grep everything
grep -rni "pandoc" *
grep -rni "pandoc" ./**/Makefile
systemctl and journalctl
SERVICE=service_name.service
systemctl start $SERVICE
journalctl -u $SERVICE -f
tar && zip
tar -cvzf archive.tar.gz directory
zip -r archivename.zip directory
tar -xvf archive.tar.gz -C extracted
unzip archivename.zip -d extracted
Swap
sudo swapoff -a
sudo dd if=/dev/zero of=/swapfile bs=1G count=10
sudo chmod 0600 /swapfile
sudo mkswap /swapfile
sudo swapon /swapfile
https://askubuntu.com/a/1177939
One-liner favicon.ico generator
TO_ICONIFY=IMAGE.png
for i in 48 96 144 192; do convert $TO_ICONIFY -resize ${i}x${i} favicon-${i}x${i}.png; done; convert favicon-* favicon.ico
txt to pdf
apt install paps
paps file.txt | ps2pdf - file.pdf