Skip to content

Commit 9753e59

Browse files
committed
Guard activate PHPStan in TRAMP/remote filesystem
1 parent 2414947 commit 9753e59

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

Diff for: phpstan.el

+5-4
Original file line numberDiff line numberDiff line change
@@ -202,10 +202,11 @@ NIL
202202

203203
(defun phpstan-enabled ()
204204
"Return non-NIL if PHPStan configured or Composer detected."
205-
(or (phpstan-get-config-file)
206-
(phpstan-get-autoload-file)
207-
(and phpstan-enable-on-no-config-file
208-
(php-project-get-root-dir))))
205+
(and (not (file-remote-p default-directory)) ;; Not support remote filesystem
206+
(or (phpstan-get-config-file)
207+
(phpstan-get-autoload-file)
208+
(and phpstan-enable-on-no-config-file
209+
(php-project-get-root-dir)))))
209210

210211
(defun phpstan-get-config-file ()
211212
"Return path to phpstan configure file or `NIL'."

0 commit comments

Comments
 (0)