From: Slawomir Nowaczyk <slawomir.nowaczyk.847@student.lu.se>
Subject: Re: Default remote user name in tramp
Date: Fri, 16 Sep 2005 12:55:08 +0200 [thread overview]
Message-ID: <20050916125246.5B74.SLAWOMIR.NOWACZYK.847@student.lu.se> (raw)
In-Reply-To: <u8xxyhwdl.fsf@gmx.de>
On Thu, 15 Sep 2005 23:08:38 +0200
Michael Albinus <michael.albinus@gmx.de> wrote:
#> > Is there any chance to have the following small patch applied to
#> > tramp.el? It allows one to specify default user name for remote hosts.
#> I'm a little bit reserved applying this patch. Tramp 2.1, the
#> developpers version, has such a customization mean (both
#> `tramp-default-user´and `tramp-default-user-alist´). Tramp 2.0,
#> which is part of Emacs 22, has been frozen a while ago, and should
#> receive bug fixes only.
OK, I see... I wasn't aware Tramp is being developed outside Emacs
CVS. There is no point in applying my patch in this case.
#> So if you are couraged enough, you could use Tramp 2.1.
I have tried Tramp-2.1.3, but it doesn't work for me at all. I get
"format-spec: Invalid format string" error from macro at line 5783 of
tramp.el, in defun tramp-maybe-open-connection.
I will try to investigate further when I have time.
#> Or you could try to apply one of the recipes in
#> <http://www.gnu.org/software/tramp/#Frequently-Asked-Questions>.
#> This is from the Tramp 2.1 documentation (you'll find
#> `tramp-default-user´ there), but most of the recipes should be
#> applicable for Tramp 2.0 too.
A couple of those look interesting, although neither is as easy to use
as default user name :)
#> > Some time ago tramp used to take user-login-name as a default
#> > remote user name if it was not specified by "user@host". Now,
#> > however, default user name is nil -- which makes tramp not work
#> > unless user name is specified on every request, at least for me
#> > (I use "plink" method and it doesn't seem to recognise remote
#> > prompt "login as:" and keeps waiting for password prompt).
#>
#> That sounds like a bug. "login as:" would not be recognized as
#> login prompt, see `tramp-login-prompt-regexp´. Could you try to
#> customize that regexp to your needs, and see whether it works
#> better? Something like ".*ogin.*: *" I would recommend. Please tell
#> then whether it helps.
I tried that. When I do:
(setq tramp-login-prompt-regexp "[Ll]ogin\\( as\\)?: *")
my "login as:" prompt gets recognised and tramp proceeds trying to
login using my user-login-name... cool :)
Except there is, apparently, a bug which causes tramp to strip last
letter from user name (i.e. if my user-login-name is "slawek", tramp
tries to login using "slawe").
Setting user-login-name to "slawekX" seems to work for me at the
moment ;) I don't have any more time to hunt this bug right now, but
I will try to figure it out later.
Thanks for your ideas.
--
Best wishes,
Slawomir Nowaczyk
( slawomir.nowaczyk.847@student.lu.se )
If the code and the comments disagree, then both are probably wrong.
next prev parent reply other threads:[~2005-09-16 10:55 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-09-15 7:42 Default remote user name in tramp Slawomir Nowaczyk
2005-09-15 21:08 ` Michael Albinus
2005-09-16 10:55 ` Slawomir Nowaczyk [this message]
2005-09-18 10:50 ` Michael Albinus
2005-09-21 14:38 ` Slawomir Nowaczyk
2005-09-21 20:37 ` Michael Albinus
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20050916125246.5B74.SLAWOMIR.NOWACZYK.847@student.lu.se \
--to=slawomir.nowaczyk.847@student.lu.se \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.