config/emacs: shennanigans
This commit is contained in:
parent
3b71749933
commit
24fad69c98
1 changed files with 20 additions and 13 deletions
|
@ -1164,6 +1164,10 @@ GNU patch review metho dor sometihng idk
|
||||||
(setq mu4e-get-mail-command "offlineimap")
|
(setq mu4e-get-mail-command "offlineimap")
|
||||||
(setq mu4e-maildir "~/Mail")
|
(setq mu4e-maildir "~/Mail")
|
||||||
|
|
||||||
|
(add-hook 'mu4e-update-pre-hook 'sakomacs/pull-email-address)
|
||||||
|
|
||||||
|
(defun sakomacs/pull-email-address ()
|
||||||
|
|
||||||
(setq outlook-mail-address
|
(setq outlook-mail-address
|
||||||
(string-trim (shell-command-to-string "pass Microsoft | awk 'BEGIN {ORS=\"\"} FNR == 2{gsub(\"login: \", \"\"); gsub(/ /, \"\"); print}'")))
|
(string-trim (shell-command-to-string "pass Microsoft | awk 'BEGIN {ORS=\"\"} FNR == 2{gsub(\"login: \", \"\"); gsub(/ /, \"\"); print}'")))
|
||||||
|
|
||||||
|
@ -1173,7 +1177,7 @@ GNU patch review metho dor sometihng idk
|
||||||
"Execute COMMAND, concatenate its output with 'hello', and store it in my-greeting."
|
"Execute COMMAND, concatenate its output with 'hello', and store it in my-greeting."
|
||||||
(let ((output (shell-command-to-string command)))
|
(let ((output (shell-command-to-string command)))
|
||||||
(setq output (string-trim output))
|
(setq output (string-trim output))
|
||||||
(setq proton-mail-address (concat "@proton.me" output))))
|
(setq proton-mail-address (concat output "@proton.me"))))
|
||||||
|
|
||||||
(get-proton-mail-address-from-pass "pass 'Proton Account' | awk 'BEGIN {ORS=\"\"} FNR == 2{gsub(\"login: \", \"\"); gsub(/ /, \"\"); print}'")
|
(get-proton-mail-address-from-pass "pass 'Proton Account' | awk 'BEGIN {ORS=\"\"} FNR == 2{gsub(\"login: \", \"\"); gsub(/ /, \"\"); print}'")
|
||||||
|
|
||||||
|
@ -1183,6 +1187,9 @@ GNU patch review metho dor sometihng idk
|
||||||
(setq gmail-2-mail-address
|
(setq gmail-2-mail-address
|
||||||
(string-trim (shell-command-to-string "pass accounts.google.com/two | awk 'BEGIN {ORS=\"\"} FNR == 2{gsub(\"login: \", \"\"); gsub(/ /, \"\"); print}'")))
|
(string-trim (shell-command-to-string "pass accounts.google.com/two | awk 'BEGIN {ORS=\"\"} FNR == 2{gsub(\"login: \", \"\"); gsub(/ /, \"\"); print}'")))
|
||||||
|
|
||||||
|
|
||||||
|
)
|
||||||
|
|
||||||
(setq mu4e-context-policy 'pick-first)
|
(setq mu4e-context-policy 'pick-first)
|
||||||
(setq mu4e-compose-context-policy 'always-ask)
|
(setq mu4e-compose-context-policy 'always-ask)
|
||||||
(setq mu4e-contexts
|
(setq mu4e-contexts
|
||||||
|
|
Loading…
Reference in a new issue