nixos-configs/modules/desktop/vscode.nix

79 lines
2.2 KiB
Nix
Raw Permalink Normal View History

2024-08-20 22:58:24 +02:00
{
config,
lib,
pkgs,
...
}:
2023-03-21 10:37:27 +01:00
2024-08-20 22:58:24 +02:00
let
cfg = config.modules.desktop.vscode;
in
{
2023-03-21 10:37:27 +01:00
options.modules.desktop.vscode = {
2024-08-20 22:58:24 +02:00
enable = lib.my.mkBoolOpt false;
2023-03-21 10:37:27 +01:00
};
2024-08-20 22:58:24 +02:00
config = lib.mkIf cfg.enable {
2023-03-21 10:37:27 +01:00
home-manager.users.${config.user.name} = {
programs.vscode = {
enable = true;
package = pkgs.vscodium;
2024-08-20 22:58:24 +02:00
extensions = with pkgs.vscode-extensions; [
pkief.material-icon-theme
jnoortheen.nix-ide
arrterian.nix-env-selector
scala-lang.scala
scalameta.metals
hashicorp.terraform
bradlc.vscode-tailwindcss
asciidoctor.asciidoctor-vscode
];
2023-03-21 10:37:27 +01:00
userSettings = {
"editor.formatOnSave" = true;
"editor.quickSuggestions" = {
"strings" = true;
};
"tailwindCSS.includeLanguages" = {
"scala" = "html";
};
"tailwindCSS.experimental.classRegex" = [
2024-08-20 22:58:24 +02:00
[
"cls\\(([^)]*)\\)"
"\"([^']*)\""
]
[
"cls\\s*:=\\s*\\(?([^,^\\n^\\)]*)"
"\"([^']*)\""
]
2023-03-21 10:37:27 +01:00
];
"files.autoSave" = "onFocusChange";
"files.watcherExclude" = {
"**/.bloop" = true;
"**/.metals" = true;
"**/.ammonite" = true;
};
"gruvboxMaterial.darkContrast" = "hard";
"metals.millScript" = "mill";
"nix.enableLanguageServer" = true;
"terminal.integrated.confirmOnExit" = "hasChildProcesses";
"terraform.languageServer" = {
"external" = true;
"pathToBinary" = "";
2024-08-20 22:58:24 +02:00
"args" = [ "serve" ];
2023-03-21 10:37:27 +01:00
"maxNumberOfProblems" = 100;
"trace.server" = "off";
};
"workbench.colorTheme" = "Gruvbox Material Dark";
"workbench.iconTheme" = "material-icon-theme";
"asciidoc.use_kroki" = true;
"explorer.confirmDelete" = false;
"explorer.confirmDragAndDrop" = false;
"terminal.integrated.shellIntegration.enabled" = false;
2024-06-23 20:15:59 +02:00
"terminal.external.linuxExec" = "kitty";
2023-03-21 10:37:27 +01:00
"terminal.integrated.scrollback" = 65535;
};
};
};
};
}