From 59c5ca4816cd97fa2b27379b00972e8705b28bfb Mon Sep 17 00:00:00 2001 From: Noah Masur <7386960+nmasur@users.noreply.github.com> Date: Mon, 17 Mar 2025 23:30:38 -0400 Subject: [PATCH] zellij and helix config --- .../nmasur/presets/programs/fzf/default.nix | 3 -- .../modules/nmasur/presets/programs/helix.nix | 32 ++++++++++++- .../nmasur/presets/programs/zellij.nix | 45 +++++++++++++++++++ .../modules/nmasur/profiles/experimental.nix | 1 + 4 files changed, 77 insertions(+), 4 deletions(-) create mode 100644 platforms/home-manager/modules/nmasur/presets/programs/zellij.nix diff --git a/platforms/home-manager/modules/nmasur/presets/programs/fzf/default.nix b/platforms/home-manager/modules/nmasur/presets/programs/fzf/default.nix index 473fc3a..b61530d 100644 --- a/platforms/home-manager/modules/nmasur/presets/programs/fzf/default.nix +++ b/platforms/home-manager/modules/nmasur/presets/programs/fzf/default.nix @@ -77,9 +77,6 @@ in # Ctrl-e bind -M insert \ce recent bind -M default \ce recent - # Ctrl-f - bind -M insert \cf fcd - bind -M default \cf fcd # Ctrl-p bind -M insert \cp projects bind -M default \cp projects diff --git a/platforms/home-manager/modules/nmasur/presets/programs/helix.nix b/platforms/home-manager/modules/nmasur/presets/programs/helix.nix index 18becfb..c6540a2 100644 --- a/platforms/home-manager/modules/nmasur/presets/programs/helix.nix +++ b/platforms/home-manager/modules/nmasur/presets/programs/helix.nix @@ -1,4 +1,9 @@ -{ config, lib, ... }: +{ + config, + pkgs, + lib, + ... +}: let cfg = config.nmasur.presets.programs.helix; @@ -14,8 +19,33 @@ in enable = true; + languages = { + + language-server.nixd = { + command = "${pkgs.nixd}/bin/nixd"; + }; + + language-server.fish-lsp = { + command = "${pkgs.fish-lsp}/bin/fish-lsp"; + }; + + language = [ + { + name = "nix"; + auto-format = true; + language-servers = [ "nixd" ]; + } + ]; + + }; + settings = { theme = "base16"; + editor.cursor-shape = { + insert = "bar"; + normal = "block"; + select = "underline"; + }; }; themes."${config.programs.helix.settings.theme}" = { diff --git a/platforms/home-manager/modules/nmasur/presets/programs/zellij.nix b/platforms/home-manager/modules/nmasur/presets/programs/zellij.nix new file mode 100644 index 0000000..c05cfee --- /dev/null +++ b/platforms/home-manager/modules/nmasur/presets/programs/zellij.nix @@ -0,0 +1,45 @@ +{ + config, + lib, + ... +}: + +let + cfg = config.nmasur.presets.programs.zellij; +in + +{ + + options.nmasur.presets.programs.zellij.enable = lib.mkEnableOption "Zellij terminal multiplexer"; + + config = lib.mkIf cfg.enable { + + programs.zellij = { + + enable = true; + enableBashIntegration = true; + enableFishIntegration = true; + enableZshIntegration = true; + + settings = { + theme = "custom"; + themes.custom = { + fg = "${config.theme.colors.base05}"; + bg = "${config.theme.colors.base02}"; + black = "${config.theme.colors.base00}"; + red = "${config.theme.colors.base08}"; + green = "${config.theme.colors.base0B}"; + yellow = "${config.theme.colors.base0A}"; + blue = "${config.theme.colors.base0D}"; + magenta = "${config.theme.colors.base0E}"; + cyan = "${config.theme.colors.base0C}"; + white = "${config.theme.colors.base05}"; + orange = "${config.theme.colors.base09}"; + }; + }; + + }; + + }; + +} diff --git a/platforms/home-manager/modules/nmasur/profiles/experimental.nix b/platforms/home-manager/modules/nmasur/profiles/experimental.nix index d381138..7feb540 100644 --- a/platforms/home-manager/modules/nmasur/profiles/experimental.nix +++ b/platforms/home-manager/modules/nmasur/profiles/experimental.nix @@ -19,6 +19,7 @@ in zed-editor.enable = lib.mkDefault true; ghostty.enable = lib.mkDefault true; helix.enable = lib.mkDefault true; + zellij.enable = lib.mkDefault true; }; home.packages = [