дзеркало
https://github.com/l0ng-ai/openidea.git
синхронізовано 2026-12-04 01:01:17 +02:00
A language server marked dynamic-documents (Phoxite for PHP and Blade) is sent the other-language documents it registers a document selector for, such as a framework's YAML, XML or JSON files, alongside their own servers. Malformed selectors match no documents, relative glob restrictions are kept, and withdrawing a selector closes the documents it opened. Co-authored-by: samehelhawary <[email protected]>
81 рядки
2.9 KiB
TOML
81 рядки
2.9 KiB
TOML
id = "php"
|
||
name = "PHP"
|
||
extensions = ["php", "phtml", "php3", "php4", "php5", "phps", "phpt"]
|
||
first-line = "^(<\\?php|#!.*\\bphp\\b)"
|
||
line-comment = "//"
|
||
block-comment = ["/*", "*/"]
|
||
indent = { tab-size = 4, insert-spaces = true }
|
||
ui-mode = "PHP"
|
||
tree-sitter = "php"
|
||
|
||
[[language-servers]]
|
||
name = "intelephense"
|
||
command = "intelephense"
|
||
args = ["--stdio"]
|
||
root-markers = ["composer.json", ".phpactor.json", "index.php"]
|
||
install-hint = "npm i -g intelephense"
|
||
# Intelephense applies the PHP version only to documents it parses after reading it.
|
||
resync-on-configuration = true
|
||
|
||
[[language-servers]]
|
||
name = "phpantom"
|
||
# PHPantom 1.1.0 can cancel these operations without ending server-created progress.
|
||
ignored-progress-token-prefixes = ["find_references", "goto_implementation"]
|
||
fallback = true
|
||
command = "phpantom_lsp"
|
||
args = []
|
||
root-markers = ["composer.json", "index.php"]
|
||
install-hint = "Install PHPantom in Settings › Languages & Frameworks › Language Servers"
|
||
|
||
[[language-servers]]
|
||
name = "phpactor"
|
||
# Alternative: used only when the server above is not installed.
|
||
fallback = true
|
||
command = "phpactor"
|
||
args = ["language-server"]
|
||
root-markers = ["composer.json", ".phpactor.json"]
|
||
install-hint = "Install Phpactor in Settings › Languages & Frameworks › Language Servers (it runs on PHP)"
|
||
|
||
# Alternative with its own Laravel and Blade support. https://github.com/samehelhawary/phoxite
|
||
[[language-servers]]
|
||
name = "phoxite"
|
||
fallback = true
|
||
command = "phoxite-lsp"
|
||
args = []
|
||
root-markers = ["composer.json", "artisan", "index.php"]
|
||
# It answers the Laravel strings itself.
|
||
replaces = ["laravel-lsp"]
|
||
# It asks for the files of the frameworks it finds: a WordPress project's scripts, a
|
||
# Drupal module's YAML, a Magento module's XML, a Joomla extension's manifests.
|
||
dynamic-documents = true
|
||
install-hint = "Install Phoxite in Settings › Languages & Frameworks › Language Servers"
|
||
|
||
# Alternative whose engine ships as native builds for Windows, macOS and Linux;
|
||
# only the npm launcher needs Node. Some features (refactorings, call and type
|
||
# hierarchy) need a DEVSENSE licence. https://docs.devsense.com/other/lsp/docs/
|
||
[[language-servers]]
|
||
name = "devsense-php-ls"
|
||
fallback = true
|
||
command = "devsense-php-ls"
|
||
args = []
|
||
root-markers = ["composer.json", "index.php"]
|
||
# It answers the Laravel strings itself.
|
||
replaces = ["laravel-lsp"]
|
||
install-hint = "npm i -g devsense-php-ls"
|
||
|
||
# Laravel projects only: hover, definition and completion inside
|
||
# config('…'), route('…') and view('…'). Last: Intelephense keeps PHP hover,
|
||
# rename and symbols. https://github.com/laravel/lsp
|
||
[[language-servers]]
|
||
name = "laravel-lsp"
|
||
command = "laravel-lsp"
|
||
args = []
|
||
root-markers = ["artisan"]
|
||
require-root-marker = true
|
||
install-hint = "composer global require laravel/lsp"
|
||
|
||
[debugger]
|
||
adapter = "php-debug"
|
||
command = "php-debug-adapter"
|
||
install-hint = "Install PHP Debug (Xdebug) in Settings › Languages & Frameworks › Language Servers, and enable Xdebug"
|