From 1476be164b8eadb258301015b6fd21dcb64118c0 Mon Sep 17 00:00:00 2001 From: "Jason A. Donenfeld" Date: Sun, 23 Mar 2014 05:57:39 -0300 Subject: umask: allow overridable Suggested-by: Matthew Richardson --- man/pass.1 | 3 +++ src/password-store.sh | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/man/pass.1 b/man/pass.1 index c09e228..668206d 100644 --- a/man/pass.1 +++ b/man/pass.1 @@ -359,6 +359,9 @@ for more info. Specifies the number of seconds to wait before restoring the clipboard, by default \fI45\fP seconds. .TP +.I PASSWORD_STORE_UMASK +Sets the umask of all files modified by pass, by default \fI077\fP. +.TP .I EDITOR The location of the text editor used by \fBedit\fP. .SH SEE ALSO diff --git a/src/password-store.sh b/src/password-store.sh index f2ec8ec..e9a3c39 100755 --- a/src/password-store.sh +++ b/src/password-store.sh @@ -3,7 +3,7 @@ # Copyright (C) 2012 - 2014 Jason A. Donenfeld . All Rights Reserved. # This file is licensed under the GPLv2+. Please see COPYING for more information. -umask 077 +umask "${PASSWORD_STORE_UMASK:-077}" GPG_OPTS="--quiet --yes --compress-algo=none" GPG="gpg" -- cgit v1.2.3-54-g00ecf