From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Tak Ota Newsgroups: gmane.emacs.devel Subject: Re: Tramp Trips Date: Wed, 07 Aug 2002 11:04:58 -0700 (PDT) Organization: Sony Electronics Inc. Sender: emacs-devel-admin@gnu.org Message-ID: <20020807.110458.01363712.Takaaki.Ota@am.sony.com> References: <20020806.113110.60849126.Takaaki.Ota@am.sony.com> NNTP-Posting-Host: localhost.gmane.org Mime-Version: 1.0 Content-Type: Text/Plain; charset=iso-8859-15 Content-Transfer-Encoding: quoted-printable X-Trace: main.gmane.org 1028743530 2417 127.0.0.1 (7 Aug 2002 18:05:30 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Wed, 7 Aug 2002 18:05:30 +0000 (UTC) Cc: emacs-devel@gnu.org Return-path: Original-Received: from quimby.gnus.org ([80.91.224.244]) by main.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 17cVBY-0000cs-00 for ; Wed, 07 Aug 2002 20:05:28 +0200 Original-Received: from fencepost.gnu.org ([199.232.76.164]) by quimby.gnus.org with esmtp (Exim 3.12 #1 (Debian)) id 17cVXG-0005Fa-00 for ; Wed, 07 Aug 2002 20:27:54 +0200 Original-Received: from localhost ([127.0.0.1] helo=fencepost.gnu.org) by fencepost.gnu.org with esmtp (Exim 3.35 #1 (Debian)) id 17cVCA-0005Kr-00; Wed, 07 Aug 2002 14:06:06 -0400 Original-Received: from mail2.fw-sj.sony.com ([160.33.82.69]) by fencepost.gnu.org with esmtp (Exim 3.35 #1 (Debian)) id 17cVBd-0005Ih-00 for ; Wed, 07 Aug 2002 14:05:33 -0400 Original-Received: from mail1.bc.in.sel.sony.com (mail1.bc.in.sel.sony.com [43.144.65.11]) by mail2.fw-sj.sony.com (8.8.8/8.8.8) with ESMTP id SAA10289; Wed, 7 Aug 2002 18:05:31 GMT Original-Received: by mail1.bc.in.sel.sony.com id SAA11179; Wed, 7 Aug 2002 18:04:59 GMT Original-To: Kai.Grossjohann@CS.Uni-Dortmund.DE In-Reply-To: X-Telephone: +1-858-942-3239 X-Fax------: +1-858-942-9142 X-SnailMail: 16450 West Bernardo Drive MZ7205, San Diego, CA 92127-1804 X-Mailer: Mew-3.0.60 on Emacs-21.3.50.1 (i386-msvc-nt5.0.2195) of 2002-08-07 Errors-To: emacs-devel-admin@gnu.org X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.0.11 Precedence: bulk List-Help: List-Post: List-Subscribe: , List-Id: Emacs development discussions. List-Unsubscribe: , List-Archive: Xref: main.gmane.org gmane.emacs.devel:6342 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:6342 Wed, 07 Aug 2002 12:34:23 +0200: Kai.Grossjohann@CS.Uni-Dortmund.DE (Ka= i Gro=DFjohann) wrote: > What's tramp-file-name-structure when this happens? It should be: > = > /---- > | tramp-file-name-structure's value is = > | ("\\`/\\(\\([a-zA-Z0-9-]+\\):\\)?\\(\\([^:@/]+\\)@\\)?\\([^:/]+\\):= \\(.*\\)\\'" 2 4 5 6) > | = > | = > | *List of five elements (REGEXP METHOD USER HOST FILE), detailing th= e tramp file name structure. > | = > | The first element REGEXP is a regular expression matching a tramp f= ile > | name. The regex should contain parentheses around the method name,= > | the user name, the host name, and the file name parts. > | = > | The second element METHOD is a number, saying which pair of > | parentheses matches the method name. The third element USER is > | similar, but for the user name. The fourth element HOST is similar= , > | but for the host name. The fifth element FILE is for the file name= .= > | These numbers are passed directly to `match-string', which see. Th= at > | means the opening parentheses are counted to identify the pair. > | = > | See also `tramp-file-name-regexp' and `tramp-make-tramp-file-format= '. > | = > | You can customize this variable. > | = > | Defined in `tramp'. > \---- This is what I get. It looks slightly different from yours. tramp-file-name-structure's value is = ("\\`/r\\(@\\([a-z0-9]+\\)\\)?:\\(\\([-a-z0-9_#]+\\)@\\)?\\([-a-z0-9.= ]+\\):\\(.*\\)\\'" 2 4 5 6) *List of five elements (REGEXP METHOD USER HOST FILE), detailing the = tramp file name structure. The first element REGEXP is a regular expression matching a tramp fil= e name. The regex should contain parentheses around the method name, the user name, the host name, and the file name parts. The second element METHOD is a number, saying which pair of parentheses matches the method name. The third element USER is similar, but for the user name. The fourth element HOST is similar, but for the host name. The fifth element FILE is for the file name. These numbers are passed directly to `match-string', which see. That= means the opening parentheses are counted to identify the pair. See also `tramp-file-name-regexp' and `tramp-make-tramp-file-format'.= You can customize this variable. Defined in `tramp'. M-x tramp-version returns this. "$Id: tramp.el,v 2.0.2.3 2001/03/28 21:44:30 grossjoh Exp $" > What happens when you eval the following Lisp expression? (The > second line shows the result when I do it.) > = > (tramp-dissect-file-name "/ota@xenon:~/") > [cl-struct-tramp-file-name nil "sm" "ota" "xenon" "~/"] > = > The "sm" is wrong. I think it's due to our broken local config. It > should be "ssh". It ends up with the same error as this. Debugger entered--Lisp error: (error "Not a tramp file name: /ota@xenon= :~/") signal(error ("Not a tramp file name: /ota@xenon:~/")) error("Not a tramp file name: %s" "/ota@xenon:~/") (if (string-match (nth 0 tramp-file-name-structure) name) nil (error = "Not a tramp file name: %s" name)) (unless (string-match (nth 0 tramp-file-name-structure) name) (error = "Not a tramp file name: %s" name)) (progn (unless (string-match ... name) (error "Not a tramp file name:= %s" name)) (setq method (or ... tramp-default-method)) (if (member met= hod tramp-multi-methods) (tramp-dissect-multi-file-name name) (make-tra= mp-file-name :multi-method nil :method method :user ... :host ... :path= ...))) (unwind-protect (progn (unless ... ...) (setq method ...) (if ... ...= ...)) (set-match-data save-match-data-internal)) (let ((save-match-data-internal ...)) (unwind-protect (progn ... ... = ...) (set-match-data save-match-data-internal))) (save-match-data (unless (string-match ... name) (error "Not a tramp = file name: %s" name)) (setq method (or ... tramp-default-method)) (if (= member method tramp-multi-methods) (tramp-dissect-multi-file-name name)= (make-tramp-file-name :multi-method nil :method method :user ... :host= ... :path ...))) (let (method) (save-match-data (unless ... ...) (setq method ...) (if= ... ... ...))) tramp-dissect-file-name("/ota@xenon:~/")