This Project for CommandLine Applications. includes configs and documentation. https://mrinjamul.github.io/unTutorials
[GPG backup and restore]
gpg --list-secret-keys
gpg --list-secret-keys --keyid-format LONG
gpg --armor --export <key-id>
git config --global user.signingkey "<secret_id>"
git config --global commit.gpgsign true
export GPG_TTY=\$(tty)
gpg -a --export <user email> > admin-public-gpg-key
gpg -a --export-secret-keys <user email> > admin-secret-gpg-key
gpg --export-ownertrust > admin-ownertrust-gpg.txt
gpg --import admin-secret-gpg-key
gpg --import-ownertrust admin-ownertrust-gpg.txt
.gnugpg
directory is empty then configure gpg using following command: gpgconf --kill gpg-agent