From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: rekado Newsgroups: gmane.emacs.bugs Subject: bug#18782: 24.3; Eshell constructs bad path when executing script in current directory on remote host Date: Tue, 23 Dec 2014 18:53:30 +0100 Message-ID: <87zjae6yn9.fsf@mango.localdomain> References: <87a94pak9i.fsf@elephly.net> <87bnmzh9zy.fsf@gmx.de> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1419357270 12823 80.91.229.3 (23 Dec 2014 17:54:30 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 23 Dec 2014 17:54:30 +0000 (UTC) Cc: 18782@debbugs.gnu.org To: Michael Albinus Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Tue Dec 23 18:54:22 2014 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Y3Tf3-0008JS-Jg for geb-bug-gnu-emacs@m.gmane.org; Tue, 23 Dec 2014 18:54:21 +0100 Original-Received: from localhost ([::1]:45707 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Y3Tf2-0008DV-IB for geb-bug-gnu-emacs@m.gmane.org; Tue, 23 Dec 2014 12:54:20 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:35168) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Y3Tes-0008DC-F5 for bug-gnu-emacs@gnu.org; Tue, 23 Dec 2014 12:54:17 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Y3Tek-0006Hr-OF for bug-gnu-emacs@gnu.org; Tue, 23 Dec 2014 12:54:10 -0500 Original-Received: from debbugs.gnu.org ([140.186.70.43]:46633) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Y3Tek-0006Hl-L2 for bug-gnu-emacs@gnu.org; Tue, 23 Dec 2014 12:54:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1Y3Tek-0006nu-11 for bug-gnu-emacs@gnu.org; Tue, 23 Dec 2014 12:54:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: rekado Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 23 Dec 2014 17:54:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 18782 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 18782-submit@debbugs.gnu.org id=B18782.141935722426127 (code B ref 18782); Tue, 23 Dec 2014 17:54:01 +0000 Original-Received: (at 18782) by debbugs.gnu.org; 23 Dec 2014 17:53:44 +0000 Original-Received: from localhost ([127.0.0.1]:55999 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1Y3TeR-0006nK-KR for submit@debbugs.gnu.org; Tue, 23 Dec 2014 12:53:43 -0500 Original-Received: from sender1.zohomail.com ([74.201.84.155]:29917) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1Y3TeP-0006nB-GU for 18782@debbugs.gnu.org; Tue, 23 Dec 2014 12:53:42 -0500 Original-Received: from localhost (brln-d9ba6679.pool.mediaWays.net [217.186.102.121]) by mx.zohomail.com with SMTPS id 1419357214575441.9784250472752; Tue, 23 Dec 2014 09:53:34 -0800 (PST) In-reply-to: <87bnmzh9zy.fsf@gmx.de> X-ZohoMailClient: External X-Zoho-Virus-Status: 2 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:97692 Archived-At: Michael Albinus writes: > I've debugged this problem. Looks like the following patch in eshell > solves it: > > --8<---------------cut here---------------start------------->8--- > *** /usr/local/src/emacs/lisp/eshell/esh-ext.el.~master~ 2014-12-19 17:33:32.333535651 +0100 > --- /usr/local/src/emacs/lisp/eshell/esh-ext.el 2014-12-19 16:21:34.443196286 +0100 > *************** > *** 296,301 **** > --- 296,306 ---- > (let ((fullname (if (file-name-directory file) file > (eshell-search-path file))) > (suffixes eshell-binary-suffixes)) > + (if (and fullname > + (not (file-remote-p fullname)) > + (file-remote-p default-directory)) > + (setq fullname (expand-file-name > + (concat "./" fullname) default-directory))) > (if (and fullname (not (or eshell-force-execution > (file-executable-p fullname)))) > (while suffixes > --8<---------------cut here---------------end--------------->8--- > > Could you, please, check? I tried this patch in Emacs 24.4 and it works for me. Thank you. -- rekado