đģ GnuPG
gpg â-gen-key
gpg -e -r $USER /dir/examplefile
gpg -d -o /dir/examplefile /dir/examplefile.(gz.)gpg
shred /dir/examplefile
rm /dir/examplefile
First convert the folder(s) to file
tar czf /dir/examplefolder.gz /dir/examplefolder
Then follow steps to encrypt/decrypt files
gpg --recv-key [key]
Key is usually printed with error message
gpg --list-keys # Target == examplekey
gpg --output mygpgkey_pub.gpg --armor --export examplekey
gpg --output mygpgkey_sec.gpg --armor --export-secret-key examplekey
gpg --import ~/mygpgkey_pub.gpg
gpg --allow-secret-key-import --import ~/mygpgkey_sec.gpg
gpg --list-keys # to verify
rm mygpgkey\_{pup,sec}.gpg
gpg --export-secret-keys > unique_name.asc
gpg --import unique_name.asc
gpg --list-keys
gpg --edit-key [expiredkey]
gpg> expire 1yr
1yr # or whatever is required. This is for key 0
Select subkeys too: key 1 # etc.