GNU bug report logs - #76955
30.1; php-ts-mode-php-executable default path may not match remote path

Previous Next

Package: emacs;

Reported by: Morgan Willcock <morgan <at> ice9.digital>

Date: Tue, 11 Mar 2025 20:11:02 UTC

Severity: normal

Found in version 30.1

Done: Eli Zaretskii <eliz <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


Message #113 received at 76955 <at> debbugs.gnu.org (full text, mbox):

From: Vincenzo Pupillo <v.pupillo <at> gmail.com>
To: Michael Albinus <michael.albinus <at> gmx.de>
Cc: Eli Zaretskii <eliz <at> gnu.org>, 76955 <at> debbugs.gnu.org,
 Morgan Willcock <morgan <at> ice9.digital>
Subject: Re: bug#76955: 30.1;
 php-ts-mode-php-executable default path may not match remote path
Date: Mon, 17 Mar 2025 10:25:36 +0100
Ok, thank you Michael.

V.

In data lunedì 17 marzo 2025 09:06:40 Ora standard dell’Europa centrale, 
Michael Albinus ha scritto:
> Vincenzo Pupillo <v.pupillo <at> gmail.com> writes:
> > Ciao Micheal,
> 
> Hi Vincenzo,
> 
> > I wrote this function based on what you wrote in your last email and what
> > I
> > read in the TRAMP documentation:
> > 
> > (defun php-ts-mode--executable-find ()
> > 
> >   (let ((php-prog
> >   
> > 	 (if (file-remote-p default-directory)
> > 	 
> > 	     (let* ((remote-path (when (boundp 'tramp-remote-path)
> > 				
> > 				tramp-remote-path))
> > 				
> > 		    (own-path (when (boundp 'tramp-own-remote-path)
> > 				
> > 				tramp-own-remote-path))
> > 				
> > 		    (exec-path (delete-dups
> > 					
> > 					(append remote-path own-path exec-path))))
> > 					
> > 	       (executable-find "php" t))
> > 	       
> >            php-ts-mode-php-executable)))
> >     
> >     php-prog))
> > 
> > Does this function make any sense?
> 
> No. Tramp doesn't use exec-path when it runs executable-find
> remotely. tramp-own-remote-path is just a symbol, it doesn't carry any
> value. Changes in remote path must be applied prior establishing a
> remote connection. Etc pp ...
> 
> Pls call just (executable-find "php" t) in your package, this works
> properly also for local default directory. Arranging for a proper
> (remote) PATH is the duty of the user.
> 
> > Vincenzo
> 
> Best regards, Michael.







This bug report was last modified 52 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.