1
0
mirror of https://github.com/TheLocehiliosan/yadm synced 2026-03-02 03:49:29 +00:00

Handle permissions for ~/.gnupg/*gpg

By default, gpg keyrings and configurations will have their permissions
locked down. The option `yadm.gpg-perms` can be used to disable.
This commit is contained in:
Tim Byrne
2015-08-07 07:18:22 -05:00
parent cbb854a32b
commit 3a1a370efb
2 changed files with 18 additions and 4 deletions

5
yadm
View File

@@ -356,6 +356,11 @@ function perms() {
GLOBS=("${GLOBS[@]}" ".ssh" ".ssh/*")
fi
#; include all gpg files (unless disabled)
if [[ $(config --bool yadm.gpg-perms) != "false" ]] ; then
GLOBS=("${GLOBS[@]}" ".gnupg" ".gnupg/*")
fi
#; include globs found in YADM_ENCRYPT (if present)
if [ -f "$YADM_ENCRYPT" ] ; then
while IFS='' read -r glob || [ -n "$glob" ]; do