[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: auth-source.el API change: Gnus and Emacs sync
From: |
Ted Zlatanov |
Subject: |
Re: auth-source.el API change: Gnus and Emacs sync |
Date: |
Fri, 11 Feb 2011 11:28:35 -0600 |
User-agent: |
Gnus/5.110011 (No Gnus v0.11) Emacs/24.0.50 (gnu/linux) |
On Fri, 11 Feb 2011 17:37:09 +0100 Michael Albinus <address@hidden> wrote:
MA> Ted Zlatanov <address@hidden> writes:
>> I attach a revised patch against Emacs that DTRT inside tramp.el itself
>> (I think). Please check the logic because I don't know the Tramp
>> internals so well. Also we could pass `tramp-current-user' with the
>> :user search key to `auth-source-search', if it's known. I don't know
>> if that's TRT for Tramp.
MA> You're patch looks OK to me (but I haven't tested). If a user is given
MA> in the remote file name, it is set in `tramp-current-user', indeed;
MA> otherwise `tramp-current-user' is nil. So you could check it and use it
MA> when non-nil.
How about this:
(setq auth-info
(tramp-compat-funcall
'auth-source-search
:max 1
:user (or tramp-current-user t)
:host tramp-current-host
:port tramp-current-method))
That will match any user if tramp-current-user is nil.
Ted
- auth-source.el API change: Gnus and Emacs sync, Ted Zlatanov, 2011/02/10
- Re: auth-source.el API change: Gnus and Emacs sync, Michael Albinus, 2011/02/11
- tramp-imap removal? (was: auth-source.el API change: Gnus and Emacs sync), Ted Zlatanov, 2011/02/11
- Re: tramp-imap removal?, Robert Pluim, 2011/02/11
- Re: tramp-imap removal?, Ted Zlatanov, 2011/02/12
- Re: tramp-imap removal?, Michael Albinus, 2011/02/13
Re: auth-source.el API change: Gnus and Emacs sync, Ted Zlatanov, 2011/02/12