From 67ce8ffdd6dd9e2f56d94d32d0e7c950025dbe41 Mon Sep 17 00:00:00 2001 From: Sakooooo <78461130+Sakooooo@users.noreply.github.com> Date: Sun, 13 Oct 2024 14:31:48 +0400 Subject: [PATCH] config/emacs: pinentry --- config/emacs/emacs.org | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/config/emacs/emacs.org b/config/emacs/emacs.org index 2ef4f017..dd63c9a3 100644 --- a/config/emacs/emacs.org +++ b/config/emacs/emacs.org @@ -621,7 +621,11 @@ kept-old-versions 5) (use-package pinentry :config (setq epa-pinentry-mode 'loopback)) - (pinentry-start)) + (pinentry-start) + (defun pinentry-emacs (desc prompt ok error) + (let ((str (read-passwd (concat (replace-regexp-in-string "%22" "\"" (replace-regexp-in-string "%0A" "\n" desc)) prompt ": ")))) + str)) + ) #+end_src ** Password-Store #+begin_src emacs-lisp