nix-configs/modules/shell/helix.nix

70 lines
1.7 KiB
Nix

{ config, ... }:
{
home-manager.users.jade = { pkgs, ... }: {
home = {
sessionVariables.EDITOR = "hx";
packages = [
pkgs.nil
pkgs.haskell-language-server
pkgs.nodePackages_latest.vscode-html-languageserver-bin
pkgs.nodePackages_latest.vscode-json-languageserver-bin
pkgs.nodePackages_latest.vscode-css-languageserver-bin
pkgs.nodePackages_latest.bash-language-server
];
};
programs.helix = {
enable = true;
settings = {
theme = "gruvbox";
editor = {
line-number = "relative";
lsp.display-messages = true;
indent-guides = {
render = true;
character = "";
};
whitespace = {
render = {
space = "all";
tab = "all";
newline = "none";
};
characters = {
space = "·";
nbsp = "";
tab = "";
};
};
};
keys.normal = {
space."=" = ":fmt";
};
};
languages = {
language-server."nu-builtin-lsp" = {
command = "${config.users.defaultUserShell}/bin/nu";
args = [ "--lsp" ];
};
language-server."rust-analyzer" = {
config = {
check.command = "clippy";
};
};
# "php" = {
# name = "php";
# file-types = [ "php" ];
# language-server = {
# command = "psalm";
# args = ["--language-server"];
# };
# };
language = [
{
name = "nu";
language-servers = [ "nu-builtin-lsp" ];
}
];
};
};
};
}