GNU bug report logs -
#76955
30.1; php-ts-mode-php-executable default path may not match remote path
Previous Next
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
View this message in rfc822 format
Ciao Micheal,
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?
Vincenzo
In data domenica 16 marzo 2025 09:34:09 Ora standard dell’Europa centrale,
Michael Albinus ha scritto:
> Morgan Willcock <morgan <at> ice9.digital> writes:
>
> Hi,
>
> > That said, I do not claim to be TRAMP expert, I just use it. A TRAMP
> > maintainer is probably better positioned to clarify the preferable way
> > to configure paths to executables so they work locally and remotely.
>
> Tramp recommends to use (executable-find "php" 'remote) . This requires
> to set a proper PATH on the remote side. Experience tells, that likely,
> you will run into further problems if you haven't set the remote (and
> local) PATH accordingly.
>
> Users might apply hard-coded values, like "/exotic/path/php" or
> "php". This is what connection-local variables are good for.
>
> But a package should offer the proper way of setting.
>
> 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.