combined shell with shell-tools

This commit is contained in:
John Lancaster
2026-03-08 12:37:00 -05:00
parent 9432f35ce8
commit f7735089df
2 changed files with 30 additions and 34 deletions

View File

@@ -1,13 +1,27 @@
{ inputs, ... }: # This module provides all the shell options
{ inputs, lib, ... }:
{ {
flake.homeModules.shell-tools = { pkgs, ... }: { flake.homeModules.shell-tools = { config, pkgs, ... }: {
options.shell.program = lib.mkOption {
type = lib.types.enum [ "bash" "zsh" ];
default = "zsh";
description = "Which interactive shell configuration to enable.";
};
imports = with inputs.self.homeModules; [ imports = with inputs.self.homeModules; [
shell # Includes option to select between zsh and bash bash
zsh
# Tools # Tools
eza eza
files files
]; ];
config = {
programs.bash.enable = lib.mkForce (config.shell.program == "bash");
programs.zsh.enable = lib.mkForce (config.shell.program == "zsh");
home.shell.enableShellIntegration = true;
home.packages = with pkgs; [ home.packages = with pkgs; [
wget wget
curl curl
@@ -20,4 +34,5 @@
xclip xclip
]; ];
}; };
};
} }

View File

@@ -1,19 +0,0 @@
{ inputs, lib, ... }:
{
flake.homeModules.shell = { config, ... }:
{
options.shell.program = lib.mkOption {
type = lib.types.enum [ "bash" "zsh" ];
default = "zsh";
description = "Which interactive shell configuration to enable.";
};
imports = with inputs.self.homeModules; [ bash zsh ];
config = {
programs.bash.enable = lib.mkForce (config.shell.program == "bash");
programs.zsh.enable = lib.mkForce (config.shell.program == "zsh");
home.shell.enableShellIntegration = true;
};
};
}