summaryrefslogtreecommitdiff
path: root/modules/auth-config.el
diff options
context:
space:
mode:
Diffstat (limited to 'modules/auth-config.el')
-rw-r--r--modules/auth-config.el6
1 files changed, 5 insertions, 1 deletions
diff --git a/modules/auth-config.el b/modules/auth-config.el
index 2b52087e..c3000f7f 100644
--- a/modules/auth-config.el
+++ b/modules/auth-config.el
@@ -40,7 +40,11 @@
:config
(epa-file-enable)
;; (setq epa-pinentry-mode 'loopback) ;; emacs request passwords in minibuffer
- (setq epg-gpg-program "gpg2")) ;; force use gpg2 (not gpg v.1)
+ (setq epg-gpg-program "gpg2") ;; force use gpg2 (not gpg v.1)
+
+ ;; Update gpg-agent with current DISPLAY environment
+ ;; This ensures pinentry can open GUI windows when Emacs starts
+ (call-process "gpg-connect-agent" nil nil nil "updatestartuptty" "/bye"))
;; ---------------------------------- Plstore ----------------------------------
;; Encrypted storage used by oauth2-auto for Google Calendar tokens.