[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Loading local .emacs from remote machine

From: Kai Großjohann
Subject: Re: Loading local .emacs from remote machine
Date: Tue, 04 Feb 2003 18:30:32 +0100
User-agent: Gnus/5.090015 (Oort Gnus v0.15) Emacs/21.3.50 (i686-pc-linux-gnu) writes:

> There I find and get tramp-2.0.28.tar.gz (dated 23-Dec-2002), untar it
> into /usr/share/emacs/site-lisp, creating the files in a subdir of
> site-lisp called tramp-2.0.28.  Then I go to
> /usr/share/emacs/site-lisp/tramp-2.0.28/ and run "make EMACS=emacs all"
> to create the *.elc files.  From this I get some error messages at the 
> end like:
> ==============================================================
> ...
> test -d ../info || mkdir ../info
> makeinfo --footnote-style=end --no-split -o ../info/tramp tramp.texi
> tramp.texi:66: Unknown command `copying'.
> tramp.texi:88: Unmatched `@end'.
> tramp.texi:143: Unknown command `insertcopying'.
> makeinfo: Removing output file `../info/tramp' due to errors; use 
> --force to preserve.
> make[1]: *** [tramp] Error 2
> make[1]: Leaving directory 
> `/usr/share/emacs/site-lisp/tramp-2.0.28/texi'
> make: *** [all] Error 2
> ==============================================================

Tramp requires Texinfo 4.2 to build the info files, 4.1 is too old.
The new command `copying' makes sure that the copying information
comes out in all formats of the document (previous Texinfo documents
missed the copying information in the HTML format).

I didn't try to fix it because it was a somewhat political decision
to use the new Texinfo version.  (Maybe I would have refrained from
the command had I known what it entails...  Maybe I should make some
backward compatibility hack.)

> When I open the directory 
> "/usr/share/emacs/site-lisp/tramp-2.0.28/texi", put the cursor on 
> tramp.texi, and press "L", I get "Failed to load 1 of 1 file-- type ? 
> for details ((tramp.texi)).  

`L' is for Lisp files (*.el), not Texinfo files (*.texi).

> Subsequently doing "M-x makeinfo-buffer" yeilds "[No match]".

I think it's M-x texinfo-format-buffer RET...

> But moving along...

Wow, very persevering.

> I add:
> (add-to-list 'load-path "/usr/share/emacs/site-lisp/tramp/lisp/")
> (require 'tramp)
> to my .emacs, create a symlink from tramp-2.0.28 to tramp, and do "C-x 
> C-e" at the ends of the above two lines.  Fine.

Yes, that's the right thing to do.

It would be nice to have proper build scripts, but given that Tramp is
included in both Emacs and XEmacs, my motivation for making proper
build scripts was so-so.  And also, it's enough to frob load-path,

> Then I skip the next part about using the install-info command to add
> the directory to the search path for Info (since the info file wasn't
> created).  And that's about all there is to the install section of 
> <>.  
> Then I skip the configuration section and just down to "Using tramp"  
> just to test it out.  Doing "C-x C-f Return /userid@"  
> prompts me for the password (which I successfully enter), but then hangs
> for minutes (seemingly permanently) with "tramp: 'Setting shell prompt"  
> in the minibuffer.  Hmmm....
> I've ssh'd and scp'd to and from this site before many times, so that's 
> not the deal.  The prompt on the remote system is of the form 
> "userid@hostname:/path/to/file # " and maybe this has tramp baffled.  
> Doing C-g finally gets me control of emacs again.

Yes, I also guess that the shell prompt wasn't recognized.  Lessee
now, what is the default value of tramp-shell-prompt-pattern?  Hm.
It should have matched this prompt.

So I'm somewhat confused.

Could you put (setq tramp-verbose 10) and (setq tramp-debug-buffer t)
in ~/.emacs and try again and show me the *tramp/foo* buffer in
addition to the *debug tramp/foo* buffer?

Also, it would be good to do M-x toggle-debug-on-quit RET before
trying, then C-g will give you a backtrace.  Please send it, too.

Oh, and removing tramp.elc before starting Emacs will give a prettier

> So then to help tramp recognize the shell prompt, I add this to-- and
> try a few variations of it in-- ".emacs":
> (add-to-list 'tramp-shell-prompt-pattern 
> '("[-,0-9,A-Z,a-z]+\@[-,0-9,A-Z,a-z]+\:[-,0-9,A-Z,a-z,/]+\ \[#$]\ "))
> (all on one line).  None have worked; trying to load it I get "Wrong
> type argument: listp ..."

The regexp syntax is weird.  For instance, [a-z,A-Z] matches
lowercase letters and uppercase letters and the comma...

But the main problem is that tramp-shell-prompt-pattern is not
supposed to be a list.  It's supposed to be a string.

> I have to say, Kai, I loved using your ange-ftp, and eventually hope to 
> use tramp some day.  Maybe today isn't the day.

I didn't write Ange-FTP, that was done by Ange (Andy Norman, I
believe) initially.  Afterwords, others have made changes, of course,
but I wasn't among them as I recall.

So much trouble you had, I'm sorry for this.
A turnip curses Elvis

reply via email to

[Prev in Thread] Current Thread [Next in Thread]