Move nvim config
This commit is contained in:
52
modules/home/dev.nix
Normal file
52
modules/home/dev.nix
Normal file
@@ -0,0 +1,52 @@
|
||||
{ config, pkgs, lib, ... }:
|
||||
|
||||
let
|
||||
cfg = config.dot.llm;
|
||||
in
|
||||
{
|
||||
options.dot.llm = {
|
||||
enable = lib.mkEnableOption "LLM tools";
|
||||
claude-code.enable = lib.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = false;
|
||||
description = "Enable claude-code";
|
||||
};
|
||||
opencode.enable = lib.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = false;
|
||||
description = "Enable opencode";
|
||||
};
|
||||
gemini-cli.enable = lib.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = false;
|
||||
description = "Enable gemini-cli";
|
||||
};
|
||||
bubblewrap.enable = lib.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = pkgs.stdenv.isLinux;
|
||||
description = "Enable bubblewrap (Linux only)";
|
||||
};
|
||||
};
|
||||
|
||||
config = lib.mkMerge [
|
||||
{
|
||||
programs.direnv = {
|
||||
enable = true;
|
||||
enableZshIntegration = true;
|
||||
nix-direnv.enable = true;
|
||||
};
|
||||
|
||||
home.packages = with pkgs; [
|
||||
visidata
|
||||
];
|
||||
}
|
||||
|
||||
(lib.mkIf cfg.enable {
|
||||
home.packages =
|
||||
(lib.optional cfg.claude-code.enable pkgs.unstable.claude-code) ++
|
||||
(lib.optional cfg.opencode.enable pkgs.unstable.opencode) ++
|
||||
(lib.optional cfg.gemini-cli.enable pkgs.unstable.gemini-cli) ++
|
||||
(lib.optional (cfg.bubblewrap.enable && pkgs.stdenv.isLinux) pkgs.unstable.bubblewrap);
|
||||
})
|
||||
];
|
||||
}
|
||||
Reference in New Issue
Block a user