aboutsummaryrefslogtreecommitdiff
path: root/modules/home/editors/vscode/default.nix
diff options
context:
space:
mode:
authorschererleander <leander@schererleander.de>2026-02-05 12:03:07 +0100
committerschererleander <leander@schererleander.de>2026-02-05 15:19:41 +0100
commit3b13d9a2a367db84d48940460532c17a374bb488 (patch)
tree599110a39c4baecf3991fe9a58d0103a43c38896 /modules/home/editors/vscode/default.nix
parent46aa4842b98d9215baca00060c233f386a0c2188 (diff)
feat(modules): use dendritic pattern
Diffstat (limited to 'modules/home/editors/vscode/default.nix')
-rw-r--r--modules/home/editors/vscode/default.nix139
1 files changed, 0 insertions, 139 deletions
diff --git a/modules/home/editors/vscode/default.nix b/modules/home/editors/vscode/default.nix
deleted file mode 100644
index 9762d92..0000000
--- a/modules/home/editors/vscode/default.nix
+++ /dev/null
@@ -1,139 +0,0 @@
-{
- config,
- lib,
- pkgs,
- ...
-}:
-
-let
- inherit (lib)
- mkEnableOption
- mkOption
- types
- mkIf
- optionals
- ;
- cfg = config.nx.editors.vscode;
-in
-{
- options.nx.editors.vscode = {
- enable = mkEnableOption "vscode editor";
-
- useVSCodium = mkOption {
- description = "Use vscodium instead of vscode";
- type = types.bool;
- default = false;
- };
-
- theme = mkOption {
- description = "Theme to use for vscode";
- type = types.enum [
- "minimal"
- "dark"
- "light"
- ];
- default = "minimal";
- };
-
- langs = {
- cmake = mkOption {
- description = "enable cmake integration";
- type = types.bool;
- default = false;
- };
- docker = mkOption {
- description = "enable docker integration";
- type = types.bool;
- default = false;
- };
- python = mkOption {
- description = "enable python integration";
- type = types.bool;
- default = false;
- };
- go = mkOption {
- description = "enable go integration";
- type = types.bool;
- default = false;
- };
- rust = mkOption {
- description = "enable rust integration";
- type = types.bool;
- default = false;
- };
- java = mkOption {
- description = "enable java integration";
- type = types.bool;
- default = false;
- };
- lua = mkOption {
- description = "enable lua integration";
- type = types.bool;
- default = false;
- };
- tailwindcss = mkOption {
- description = "enable tailwindcss integration";
- type = types.bool;
- default = false;
- };
- };
- };
-
- config = mkIf cfg.enable {
- programs.vscode = {
- enable = true;
- package = if cfg.useVSCodium then pkgs.vscodium else pkgs.vscode;
- mutableExtensionsDir = false;
- profiles.default = {
- enableUpdateCheck = true;
- enableExtensionUpdateCheck = true;
-
- userSettings = {
- "update.mode" = "none";
- "workbench.colorTheme" =
- if cfg.theme == "minimal" then
- "Minimal"
- else if cfg.theme == "dark" then
- "Default Dark Modern"
- else
- "Default Light Modern";
- "editor.fontFamily" = "monospace";
- "editor.tabSize" = 2;
- "editor.minimap.enabled" = false;
- "terminal.integrated.cursorStyle" = "underline";
- "terminal.integrated.cursorStyleInactive" = "underline";
- "terminal.integrated.fontFamily" = "monospace";
- "terminal.integrated.fontSize" = 13;
- "git.autofetch" = true;
- "window.controlsStyle" = "custom";
- };
-
- extensions =
- with pkgs.vscode-extensions;
- [
- github.copilot
- adpyke.codesnap
- esbenp.prettier-vscode
- ]
- ++ (optionals cfg.langs.cmake [ ms-vscode.cmake-tools ])
- ++ (optionals cfg.langs.docker [ ms-azuretools.vscode-docker ])
- ++ (optionals cfg.langs.python [ ms-python.python ])
- ++ (optionals cfg.langs.go [ golang.go ])
- ++ (optionals cfg.langs.rust [ rust-lang.rust-analyzer ])
- ++ (optionals cfg.langs.java [ vscjava.vscode-maven ])
- ++ (optionals cfg.langs.lua [ sumneko.lua ])
- ++ (optionals cfg.langs.tailwindcss [ bradlc.vscode-tailwindcss ])
- ++ (optionals (cfg.theme == "minimal") (
- pkgs.vscode-utils.extensionsFromVscodeMarketplace [
- {
- name = "minimalist-dark";
- publisher = "nichabosh";
- version = "1.0.0";
- sha256 = "sha256-lw+Scfada6DycLdRT2Cz+Fd12JucglIrw3uRd2ZhabQ=";
- }
- ]
- ));
- };
- };
- };
-}