Skip to content

Instantly share code, notes, and snippets.

View lssimoes's full-sized avatar

Lucas Silva Simões lssimoes

View GitHub Profile
@lssimoes
lssimoes / gpg-import-and-export-instructions.md
Last active February 12, 2016 19:33 — forked from chrisroos/gpg-import-and-export-instructions.md
Instructions for exporting/importing (backup/restore) GPG keys

Every so often I have to restore my gpg keys and I'm never sure how best to do it. So, I've spent some time playing around with the various ways to export/import (backup/restore) keys.

Method 1

Backup the public and secret keyrings and trust database

cp ~/.gnupg/pubring.gpg /path/to/backups/
cp ~/.gnupg/secring.gpg /path/to/backups/
cp ~/.gnupg/trustdb.gpg /path/to/backups/

or, instead of backing up trustdb...

@lssimoes
lssimoes / vadown.sh
Created December 29, 2015 22:49 — forked from gabrielsimoes/vadown.sh
Download homiliae from vatican and save as html
#!/bin/bash
link=$1
if [[ ! -n $1 ]]
then
link=http://w2.vatican.va/content/francesco/pt/apost_letters/documents/papa-francesco_bolla_20150411_misericordiae-vultus.html
fi
curl $link > .tp1
@lssimoes
lssimoes / Plot_Examples.md
Created December 4, 2015 00:24 — forked from gizmaa/Plot_Examples.md
Various Julia plotting examples using PyPlot