jwiegley / emacs-async

Simple library for asynchronous processing in Emacs
GNU General Public License v3.0
838 stars 68 forks source link

using auth-sources from auth-password-store does not work #53

Closed asyncmind0 closed 6 years ago

asyncmind0 commented 9 years ago

https://github.com/DamienCassou/auth-password-store

(require 'auth-password-store)
(auth-pass-enable)
(setq send-mail-function 'async-smtpmail-send-it
      message-send-mail-function 'async-smtpmail-send-it)
thierryvolpiatto commented 9 years ago

Steven notifications@github.com writes:

https://github.com/DamienCassou/auth-password-store

I have no idea how this is working. If you want something to be fixed please develop and try to provide infos on what is missing to make it working.

If regular smtpmail-send-it is working with your package, probably you can pass these infos through the `async-smtpmail-before-send-hook'.

Thierry https://emacs-helm.github.io/helm/

asyncmind0 commented 9 years ago

I tried to require the module in the before send hook, but that failed to find the module (is there any reason for this related to async?). Im not yet very fluent in elisp/lisp but im getting there

seanfarley commented 6 years ago

Strange. I just ran into this (because I just switched to pass). I tried debugging but can't get any breakpoints to hit (presumably due to the asynchronous part).

seanfarley commented 6 years ago

With @DamienCassou's help, I was able to figure this out. auth-source-pass-enable needs to be called in the async-smtpmail-before-send-hook like so:

(add-hook 'async-smtpmail-before-send-hook #'auth-source-pass-enable)

So, I believe this issue can be closed now.

jwiegley commented 6 years ago

Thanks!