summaryrefslogtreecommitdiff
path: root/.emacs.d/modules
diff options
context:
space:
mode:
authorThanos Apollo <[email protected]>2024-02-07 18:03:36 +0200
committerThanos Apollo <[email protected]>2024-02-07 18:03:36 +0200
commit03be4c51ac6bc70c0e893692074e117b21f74cb3 (patch)
tree50ca3eb3425382c931ed2f5e4a1201bd7028f889 /.emacs.d/modules
parent5384cd03ebfa4b868a1d60d05fa6ee8a3af1c64c (diff)
emacs:(pass) Fix indentation
Diffstat (limited to '.emacs.d/modules')
-rw-r--r--.emacs.d/modules/thanos-pass.el44
1 files changed, 22 insertions, 22 deletions
diff --git a/.emacs.d/modules/thanos-pass.el b/.emacs.d/modules/thanos-pass.el
index 86f1369..0e996f6 100644
--- a/.emacs.d/modules/thanos-pass.el
+++ b/.emacs.d/modules/thanos-pass.el
@@ -35,28 +35,28 @@
(defun thanos/pass-launcher ()
"Launch Emacs as a front-end for pass."
(interactive)
- (unwind-protect
- (with-selected-frame
- (make-frame '((name . "thanos/pass-launcher")
- (fullscreen . 0)
- (undecorated . t)
- (minibuffer . only)
- (width . 70)
- (height . 15)))
- (let* ((choice (completing-read "Choose an action: "
- '("AUTO" "COPY PASS" "COPY USERNAME" "EDIT" "GENERATE")))
- (action (pcase choice
- ("AUTO" #'(lambda (entry) (let ((user (password-store-get-field entry "user")) (pass (password-store-get entry)))
- (start-process-shell-command
- "xdotool" nil
- (format "sleep 0.3 && xdotool getactivewindow type '%s' && xdotool getactivewindow key Tab && xdotool getactivewindow type '%s'"
- (if user user 'thanosapollo) pass)))))
- ("COPY PASS" #'password-store-copy)
- ("COPY USERNAME" #'(lambda (entry) (password-store-copy-field entry "user")))
- ("EDIT" #'password-store-edit)
- ("GENERATE" #'password-store-generate))))
- (funcall action (completing-read "Search: " (password-store-list)))
- (delete-frame)))))
+ (unwind-protect
+ (with-selected-frame
+ (make-frame '((name . "thanos/pass-launcher")
+ (fullscreen . 0)
+ (undecorated . t)
+ (minibuffer . only)
+ (width . 70)
+ (height . 15)))
+ (let* ((choice (completing-read "Choose an action: "
+ '("AUTO" "COPY PASS" "COPY USERNAME" "EDIT" "GENERATE")))
+ (action (pcase choice
+ ("AUTO" #'(lambda (entry) (let ((user (password-store-get-field entry "user")) (pass (password-store-get entry)))
+ (start-process-shell-command
+ "xdotool" nil
+ (format "sleep 0.3 && xdotool getactivewindow type '%s' && xdotool getactivewindow key Tab && xdotool getactivewindow type '%s'"
+ (if user user 'thanosapollo) pass)))))
+ ("COPY PASS" #'password-store-copy)
+ ("COPY USERNAME" #'(lambda (entry) (password-store-copy-field entry "user")))
+ ("EDIT" #'password-store-edit)
+ ("GENERATE" #'password-store-generate))))
+ (funcall action (completing-read "Search: " (password-store-list)))
+ (delete-frame)))))
(defun smtp-get-pass ()
"Get password for smtp."