From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: gebser@ameritech.net Newsgroups: gmane.emacs.help Subject: Re: Loading local .emacs from remote machine Date: Tue, 4 Feb 2003 16:51:59 -0500 (EST) Sender: help-gnu-emacs-bounces+gnu-help-gnu-emacs=m.gmane.org@gnu.org Message-ID: References: <848yww7y2v.fsf@lucy.is.informatik.uni-duisburg.de> Reply-To: gebser@ameritech.net NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: TEXT/PLAIN; charset=ISO-8859-1 Content-Transfer-Encoding: 8BIT X-Trace: main.gmane.org 1044395685 14442 80.91.224.249 (4 Feb 2003 21:54:45 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Tue, 4 Feb 2003 21:54:45 +0000 (UTC) Cc: gebser@Ameritech.Net Return-path: Original-Received: from monty-python.gnu.org ([199.232.76.173]) by main.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 18gB1a-0003k2-00 for ; Tue, 04 Feb 2003 22:54:38 +0100 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.10.13) id 18gB2B-0006XY-03 for gnu-help-gnu-emacs@m.gmane.org; Tue, 04 Feb 2003 16:55:15 -0500 Original-Received: from list by monty-python.gnu.org with tmda-scanned (Exim 4.10.13) id 18gB0Z-00069j-00 for help-gnu-emacs@gnu.org; Tue, 04 Feb 2003 16:53:35 -0500 Original-Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.10.13) id 18gAzJ-0004rj-00 for help-gnu-emacs@gnu.org; Tue, 04 Feb 2003 16:52:20 -0500 Original-Received: from mailhost2-bcvloh.bcvloh.ameritech.net ([66.73.20.44] helo=mailhost.bcv2.ameritech.net) by monty-python.gnu.org with esmtp (Exim 4.10.13) id 18gAyv-0004jS-00 for help-gnu-emacs@gnu.org; Tue, 04 Feb 2003 16:51:53 -0500 Original-Received: from heidegger.mousecar.net ([65.43.213.238]) by mailhost.bcv2.ameritech.net (InterMail vM.4.01.02.17 201-229-119) with ESMTP <20030204215138.LIVX16631.mailhost.bcv2.ameritech.net@heidegger.mousecar.net>; Tue, 4 Feb 2003 16:51:38 -0500 Original-To: Kai =?iso-8859-1?q?Gro=DFjohann?= In-Reply-To: <848yww7y2v.fsf@lucy.is.informatik.uni-duisburg.de> Original-cc: help-gnu-emacs@gnu.org X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1b5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Help: List-Post: List-Subscribe: , List-Archive: List-Unsubscribe: , Errors-To: help-gnu-emacs-bounces+gnu-help-gnu-emacs=m.gmane.org@gnu.org Xref: main.gmane.org gmane.emacs.help:6305 X-Report-Spam: http://spam.gmane.org/gmane.emacs.help:6305 Kai, Thanks for the feedback. I looked around and it seems I'd have to upgrade to RH 8.0 to be able to use texinfo 4.2; it would require upgrading some other more central system files. I'd like to have the info files, but today isn't the day for me to do a full upgrade. But maybe we can still get tramp working. (See below.) Kai Großjohann at 18:30 (UTC+0100) on Tue, 4 Feb 2003 said: = gebser@ameritech.net writes: = = >... = > ... = = 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.) This would help out those of us who don't upgrade with each new version that comes out. I know a lot of people still on rh 7.2. = = > 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). I was following the documentation. What would be the way to load a *.texi file? = = > Subsequently doing "M-x makeinfo-buffer" yeilds "[No match]". = = I think it's M-x texinfo-format-buffer RET... Again, the command I used was directly from the docs. = = > But moving along... = = Wow, very persevering. People say that.... Well, they don't give me a "Wow", but yeah. :) = ... = = 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, = basically. = = > 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 = > . This is where I was reading the aforementioned docs. = > = > Then I skip the configuration section and just down to "Using tramp" = > just to test it out. Doing "C-x C-f Return /userid@1.2.3.4:/etc/foo" = > 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. I don't know enough about this even to be confused.... 8\ = = 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 = backtrace. Did all this. Then tried to open a file on the same machine as before. The output of *Backtrace*: =============================================================== Signaling: (quit) accept-process-output(# 1) tramp-wait-for-output() tramp-open-connection-setup-interactive-shell(# nil nil "ken" "fencefarm") tramp-open-connection-rsh(nil nil "ken" "fencefarm") tramp-maybe-open-connection(nil nil "ken" "fencefarm") tramp-send-command(nil nil "ken" "fencefarm" "( test -d /etc/hosts 2>/dev/null; echo tramp_exit_status $? )") tramp-send-command-and-check(nil nil "ken" "fencefarm" "test -d /etc/hosts" t) tramp-handle-file-directory-p("/ken@fencefarm:/etc/hosts") apply(tramp-handle-file-directory-p "/ken@fencefarm:/etc/hosts") tramp-file-name-handler(file-directory-p "/ken@fencefarm:/etc/hosts") file-directory-p("/ken@fencefarm:/etc/hosts") find-file-noselect("/ken@fencefarm:/etc/hosts" nil nil 1) find-file("/ken@fencefarm:/etc/hosts" 1) * call-interactively(find-file) ============================================================ Here's *tramp/nil ken@fencefarm*: ============================================================ > > ///»¢ò ;Öv­  éüž­ Read from remote host fencefarm: Connection reset by peer Connection to fencefarm closed. Process *tramp/nil root@fencefarm* exited abnormally with code 255 ============================================================ And here's *debug tramp/nil ken@fencefarm* ============================================================ # Opening connection for ken@fencefarm using nil... # Waiting for prompts from remote shell # Waiting 60s for prompt from remote shell # Looking for regexp "^.*\([pP]assword\|passphrase.*\): # Looking for regexp ".*ogin: *" from remote shell # Looking for regexp "^[^#$%> ]*[#$%>] *" from remote shell # Looking for regexp "^[^#$%> ]*[#$%>] *" from remote shell # Looking for regexp "^.*\(Connection \(closed\|refused\)\|Host key verification failed\.\|Login \(Incorrect\|incorrect\)\|Name or service not known\|Permission denied\.\|Sorry, try again\.\).*\|^.*\(Received signal [0-9]+\).*" from remote shell # Looking for regexp "\(Are you sure you want to continue connecting (yes/no)\?\)\s-*" from remote shell # Looking for regexp "\(Store key in cache\? (y/n)\)\s-*" from remote shell # Looking for regexp "\(TERM = (.*)\|Terminal type\? \[.*\]\)\s-*" from remote shell # Looking for regexp "^.*\([pP]assword\|passphrase.*\): # Sending password # Looking for regexp ".*ogin: *" from remote shell # Looking for regexp "^[^#$%> ]*[#$%>] *" from remote shell # Looking for regexp "^[^#$%> ]*[#$%>] *" from remote shell # Looking for regexp "^.*\(Connection \(closed\|refused\)\|Host key verification failed\.\|Login \(Incorrect\|incorrect\)\|Name or service not known\|Permission denied\.\|Sorry, try again\.\).*\|^.*\(Received signal [0-9]+\).*" from remote shell # Looking for regexp "\(Are you sure you want to continue connecting (yes/no)\?\)\s-*" from remote shell # Looking for regexp "\(Store key in cache\? (y/n)\)\s-*" from remote shell # Looking for regexp "\(TERM = (.*)\|Terminal type\? \[.*\]\)\s-*" from remote shell # Looking for regexp "^.*\([pP]assword\|passphrase.*\): # Looking for regexp ".*ogin: *" from remote shell # Looking for regexp "^[^#$%> ]*[#$%>] *" from remote shell # Looking for regexp "^[^#$%> ]*[#$%>] *" from remote shell # Looking for regexp "^.*\(Connection \(closed\|refused\)\|Host key verification failed\.\|Login \(Incorrect\|incorrect\)\|Name or service not known\|Permission denied\.\|Sorry, try again\.\).*\|^.*\(Received signal [0-9]+\).*" from remote shell # Looking for regexp "\(Are you sure you want to continue connecting (yes/no)\?\)\s-*" from remote shell # Looking for regexp "\(Store key in cache\? (y/n)\)\s-*" from remote shell # Looking for regexp "\(TERM = (.*)\|Terminal type\? \[.*\]\)\s-*" from remote shell # Looking for regexp "^.*\([pP]assword\|passphrase.*\): # Looking for regexp ".*ogin: *" from remote shell # Looking for regexp "^[^#$%> ]*[#$%>] *" from remote shell # Looking for regexp "^[^#$%> ]*[#$%>] *" from remote shell # Looking for regexp "^.*\(Connection \(closed\|refused\)\|Host key verification failed\.\|Login \(Incorrect\|incorrect\)\|Name or service not known\|Permission denied\.\|Sorry, try again\.\).*\|^.*\(Received signal [0-9]+\).*" from remote shell # Looking for regexp "\(Are you sure you want to continue connecting (yes/no)\?\)\s-*" from remote shell # Looking for regexp "\(Store key in cache\? (y/n)\)\s-*" from remote shell # Looking for regexp "\(TERM = (.*)\|Terminal type\? \[.*\]\)\s-*" from remote shell # Looking for regexp "^.*\([pP]assword\|passphrase.*\): # Looking for regexp ".*ogin: *" from remote shell # Looking for regexp "^[^#$%> ]*[#$%>] *" from remote shell # Found remote shell prompt. # Initializing remote shell $ exec env PS1='$ ' /bin/sh # Waiting 30s for remote `/bin/sh' to come up... exec env 'PS1=$ ' /bin/sh $ # Setting up remote shell environment stty -inlcr -echo kill '^U' $ $ # Determining coding system foo bar $ # Waiting 30s for `HISTFILE=$HOME/.tramp_history; HISTSIZE=1' $ # Waiting 30s for `set +o vi +o emacs' $ # Waiting 30s for `unset MAIL MAILCHECK MAILPATH' $ # Waiting 30s for `unset CDPATH' $ # Setting shell prompt $ PS1=' ///»¢ò ;YÖv­  éüž­ '; PS2=''; PS3='' ============================================================ Here's what as ssh login from the command prompt looks like: ================================================================ $ ssh ken@fencefarm ken@fencefarm's password: Last login: Tue Feb 4 16:20:15 2003 from adsl-65-43-213-[...] ================================================================ = > ... = > '("[-,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. A string in elisp must be some really strange thing. (add-to-list 'tramp-shell-prompt-pattern "abc") also gives the same error. It seems that everything and anything I put into the third arg is a listp. It's a shame elisp is so obtuse. I'd like to learn it so's to do some helpful work on emacs. Several times I've tried to do simple things in elisp, following books and tutorials, but never had any progress with it. Maybe I need to be dyslexic. :) = = ... Thanks again for the assistance. ken -- Happy Gui-Wei 4700