feat: make options and conditionalize config
This commit is contained in:
@@ -1,5 +1,7 @@
|
||||
{
|
||||
imports = [
|
||||
../options.nix
|
||||
|
||||
./git.nix
|
||||
./fish.nix
|
||||
./nixvim
|
||||
|
||||
@@ -1,5 +1,12 @@
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
{
|
||||
|
||||
config = lib.mkIf config.kekleo.graphical {
|
||||
home.packages = with pkgs; [ nordzy-cursor-theme ];
|
||||
|
||||
programs.waybar.enable = true;
|
||||
@@ -77,4 +84,5 @@
|
||||
cursor.no_warps = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1,5 +1,11 @@
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
{
|
||||
config = lib.mkIf config.kekleo.graphical {
|
||||
programs.kitty = {
|
||||
enable = true;
|
||||
themeFile = "tokyo_night_night";
|
||||
@@ -12,4 +18,5 @@
|
||||
"ctrl+alt+enter" = "launch --cwd=current";
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1,3 +1,8 @@
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
{
|
||||
imports = [
|
||||
./opts.nix
|
||||
@@ -5,6 +10,7 @@
|
||||
./plugins
|
||||
];
|
||||
|
||||
config = lib.mkIf config.kekleo.neovim {
|
||||
programs.nixvim = {
|
||||
enable = true;
|
||||
viAlias = true;
|
||||
@@ -18,4 +24,5 @@
|
||||
|
||||
globals.mapleader = " ";
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1,5 +1,10 @@
|
||||
{ ... }:
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
{
|
||||
config = lib.mkIf config.kekleo.graphical {
|
||||
programs.rofi = {
|
||||
enable = true;
|
||||
font = "JetBrainsMono Nerd Font 11";
|
||||
@@ -35,4 +40,5 @@
|
||||
kb-mode-complete = "Control+o";
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
{
|
||||
imports = [
|
||||
../options.nix
|
||||
|
||||
./fish.nix
|
||||
./firefox.nix
|
||||
./hyprland.nix
|
||||
|
||||
@@ -1,3 +1,10 @@
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
{
|
||||
config = lib.mkIf config.kekleo.graphical {
|
||||
programs.firefox.enable = true;
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1,3 +1,10 @@
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
{
|
||||
config = lib.mkIf config.kekleo.graphical {
|
||||
programs.hyprland.enable = true;
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1,3 +1,10 @@
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
{
|
||||
config = lib.mkIf config.kekleo.graphical {
|
||||
services.displayManager.ly.enable = true;
|
||||
};
|
||||
}
|
||||
|
||||
@@ -0,0 +1,18 @@
|
||||
{
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
{
|
||||
options.kekleo = {
|
||||
graphical = lib.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = true;
|
||||
description = "Enable GUI features and programs";
|
||||
};
|
||||
neovim = lib.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = true;
|
||||
description = "Enable neovim";
|
||||
};
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user