dot

packages and services management
Log | Files | Refs | README

commit 244b45f27a0bf957167833281bb12c0dd17a557a
parent 7b50a659d59fb252cfbe5e43b8f54f2a2b733fb6
Author: Josuah Demangeon <mail@josuah.net>
Date:   Mon,  3 Dec 2018 04:22:46 +0100

gpg import export

Diffstat:
Mbin/gpg-export | 7++++---
Mbin/gpg-import | 10+++++-----
Ddot/gnupg/pubring.gpg | 2--
Ddot/gnupg/secring.gpg | 2--
Ddot/gnupg/trustdb.gpg | 2--
5 files changed, 9 insertions(+), 14 deletions(-)

diff --git a/bin/gpg-export b/bin/gpg-export @@ -1,7 +1,8 @@ -#!/bin/sh -ex +#!/bin/sh -e -mkdir -p /mnt/key/gpg +mkdir -p -m 0700 /mnt/key/gpg cd /mnt/key/gpg -cp -r "$HOME/.gnupg/private-keys-v1.d" . + +cp -r "$HOME/.gnupg/openpgp-revocs.d" "$HOME/.gnupg/private-keys-v1.d" . gpg -a --export >pubring.txt gpg --export-ownertrust >trustdb.txt diff --git a/bin/gpg-import b/bin/gpg-import @@ -1,8 +1,8 @@ -#!/bin/sh -ex +#!/bin/sh -e +cd /mnt/key/gpg mkdir -p -m 0700 "$HOME/.gnupg" -cp -r /mnt/key/gpg/private-keys-v1.d/ "$HOME/.gnupg" -gpg --import /mnt/key/gpg/pubring.txt -gpg --import-ownertrust </mnt/key/gpg/trustdb.txt - +cp -r openpgp-revocs.d private-keys-v1.d "$HOME/.gnupg" +gpg --import pubring.txt +gpg --import-ownertrust trustdb.txt diff --git a/dot/gnupg/pubring.gpg b/dot/gnupg/pubring.gpg @@ -1 +0,0 @@ -/mnt/key/gpg/pubring.gpg- \ No newline at end of file diff --git a/dot/gnupg/secring.gpg b/dot/gnupg/secring.gpg @@ -1 +0,0 @@ -/mnt/key/gpg/secring.gpg- \ No newline at end of file diff --git a/dot/gnupg/trustdb.gpg b/dot/gnupg/trustdb.gpg @@ -1 +0,0 @@ -/mnt/key/gpg/trustdb.gpg- \ No newline at end of file