Skip to content

Misc

Paperkey

Export gpg key to a printable version

https://wiki.archlinux.org/index.php/Paperkey

Public Keys

Timezone

$ sudo timedatectl set-timezone America/Los_Angeles

Images

Imagemagick

# Ubuntu
$ sudo apt-get install sudo apt install imagemagick-6.q16hdri
# Convert image from ico to png
$ convert "favicon.ico" -thumbnail 16x16 -alpha on -background none -flatten "favicon.png"

Shred

Overwrite the data of file1.txt, file2.jpg, and file3.doc using the default shredding methods.

$ shred -u file1.txt file2.jpg file3.doc

Combine PDFs

$ qpdf --empty --pages *.pdf -- out.pdf

List if a Package is Installed

apt -qq list <package name>

Disk Free Space

df -h

List Hardware

sudo lshw -short

UID

id -u $(whoami)

GID

id -g $(whoami)

Screen

Detached the previous screen and allowed me to reattach.

screen -d -r

Replace Entire Line in File

sed -i "s|^type     =.*$|type     = mysql|g" config.ini

keepachangelog

References

Back to top