Files
LazyVim/lua/lazyvim/plugins/extras/lang/php.lua

39 lines
810 B
Lua

return {
recommended = {
ft = "php",
root = { "composer.json", ".phpactor.json", ".phpactor.yml" },
},
{
"nvim-treesitter/nvim-treesitter",
opts = { ensure_installed = { "php" } },
},
{
"neovim/nvim-lspconfig",
opts = {
servers = {
phpactor = {},
},
},
},
{
"mfussenegger/nvim-dap",
optional = true,
dependencies = {
"williamboman/mason.nvim",
opts = { ensure_installed = { "php-debug-adapter" } },
},
opts = function()
local dap = require("dap")
local path = require("mason-registry").get_package("php-debug-adapter"):get_install_path()
dap.adapters.php = {
type = "executable",
command = "node",
args = { path .. "/extension/out/phpDebug.js" },
}
end,
},
}