devos/users/modules/neovim/dart.nix

21 lines
455 B
Nix
Raw Permalink Normal View History

2023-03-19 14:36:16 +01:00
{ lib, pkgs, config, ... }:
let
cfg = config.mae.nvim.dart;
in
with lib;
{
options.mae.nvim.dart.enable = lib.mkEnableOption "Enable dart support in neovim";
config = mkIf cfg.enable {
mae.nvim.lsp.servers.dartls = {
enable = true;
script = ''
{
cmd = { "${pkgs.latest.dart}/bin/dart", "language-server" },
}
'';
};
programs.neovim.plugins = with pkgs.vimPlugins; [ dart-vim-plugin ];
};
}