Add intelephense lsp to php-mode.
This commit is contained in:
parent
e06910f8eb
commit
dbe7fdfb4e
2 changed files with 9 additions and 1 deletions
|
@ -23,6 +23,10 @@ mkIf (elem "emacs::lsp" config.machine.pkgs) {
|
||||||
(setq lsp-clients-deno-import-map "./import_map.json")
|
(setq lsp-clients-deno-import-map "./import_map.json")
|
||||||
(setq lsp-clients-deno-config "./deno.json")
|
(setq lsp-clients-deno-config "./deno.json")
|
||||||
''}
|
''}
|
||||||
|
${optionalString (elem "emacs::php-mode" config.machine.pkgs) ''
|
||||||
|
(setq lsp-intelephense-php-version "8.2")
|
||||||
|
(setq lsp-intelephense-server-command `("${pkgs.nodePackages.intelephense}/bin/intelephense" "--stdio"))
|
||||||
|
''}
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -4,6 +4,10 @@ with lib;
|
||||||
|
|
||||||
mkIf (elem "emacs::php-mode" config.machine.pkgs) {
|
mkIf (elem "emacs::php-mode" config.machine.pkgs) {
|
||||||
programs.emacs.init.usePackage = {
|
programs.emacs.init.usePackage = {
|
||||||
php-mode.enable = true;
|
php-mode = {
|
||||||
|
enable = true;
|
||||||
|
hook = lib.optional (elem "emacs::lsp" config.machine.pkgs)
|
||||||
|
''(typescript-mode . (lambda () (lsp)))'';
|
||||||
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue