nixcfg/homeManagerModules/options.nix

226 lines
7.1 KiB
Nix
Raw Normal View History

{
config,
2024-06-21 17:24:33 -04:00
lib,
osConfig,
pkgs,
...
2024-07-06 19:52:05 -04:00
}: let
cfg = config.ar.home;
in {
options.ar.home = {
apps = {
alacritty.enable = lib.mkEnableOption "Alacritty terminal.";
backblaze = {
enable = lib.mkEnableOption "Backblaze-b2 client with declarative authentication.";
keyIdFile = lib.mkOption {
description = "Backblaze key ID.";
default = null;
type = lib.types.nullOr lib.types.str;
};
keyFile = lib.mkOption {
description = "Backblaze application key.";
default = null;
type = lib.types.nullOr lib.types.str;
};
};
chromium = {
enable = lib.mkEnableOption "Chromium-based browser with default extensions.";
2024-07-12 20:50:01 -04:00
package = lib.mkPackageOption pkgs "brave" {};
};
emacs.enable = lib.mkEnableOption "Emacs text editor.";
fastfetch.enable = lib.mkEnableOption "Fastfetch.";
firefox.enable = lib.mkEnableOption "Firefox web browser.";
fuzzel.enable = lib.mkEnableOption "Fuzzel app launcher.";
2024-07-24 09:26:00 -04:00
helix.enable = lib.mkEnableOption "Helix text editor.";
keepassxc = {
enable = lib.mkEnableOption "KeePassXC password manager.";
2024-07-31 17:19:08 -04:00
package = lib.mkPackageOption pkgs "keepassxc" {};
settings = lib.mkOption {
description = "KeePassXC settings.";
default = {};
type = lib.types.attrs;
};
};
2024-07-23 23:21:59 -04:00
kitty.enable = lib.mkEnableOption "Kitty terminal.";
librewolf.enable = lib.mkEnableOption "Librewolf web browser.";
nemo.enable = lib.mkOption {
description = "Cinnamon Nemo file manager.";
2024-07-06 19:52:05 -04:00
default = cfg.defaultApps.fileManager == pkgs.cinnamon.nemo;
type = lib.types.bool;
};
rofi.enable = lib.mkEnableOption "Rofi launcher.";
shell.enable = lib.mkEnableOption "Shell with defaults.";
swaylock.enable = lib.mkEnableOption "Swaylock screen locker.";
thunar.enable = lib.mkOption {
description = "Thunar file manager.";
2024-07-06 19:52:05 -04:00
default = cfg.defaultApps.fileManager == pkgs.xfce.thunar;
type = lib.types.bool;
};
tmux.enable = lib.mkEnableOption "Tmux shell session manager.";
vsCodium.enable = lib.mkEnableOption "VSCodium text editor.";
wlogout.enable = lib.mkEnableOption "Wlogout session prompt.";
2024-07-24 16:54:34 -04:00
yazi.enable = lib.mkEnableOption "Yazi terminal file manager.";
zed = {
enable = lib.mkEnableOption "Zed text editor.";
package = lib.mkPackageOption pkgs "zed-editor" {};
keymaps = lib.mkOption {
description = "Zed keymaps.";
default = [];
type = lib.types.listOf lib.types.attrs;
};
settings = lib.mkOption {
description = "Zed settings.";
default = {};
type = lib.types.attrs;
};
};
};
defaultApps = {
2024-06-28 21:07:20 -04:00
enable = lib.mkEnableOption "Declaratively set default apps and file associations.";
2024-07-12 20:50:01 -04:00
audioPlayer = lib.mkPackageOption pkgs "audio player" {default = ["celluloid"];};
editor = lib.mkPackageOption pkgs "text editor" {default = ["vscodium"];};
fileManager = lib.mkPackageOption pkgs "file manager" {default = ["cinnamon" "nemo"];};
imageViewer = lib.mkPackageOption pkgs "image viewer" {default = ["gnome" "eog"];};
pdfViewer = lib.mkPackageOption pkgs "pdf viewer" {default = ["evince"];};
terminal = lib.mkPackageOption pkgs "terminal emulator" {default = ["kitty"];};
2024-07-12 20:50:01 -04:00
terminalEditor = lib.mkPackageOption pkgs "terminal text editor" {default = ["vim"];};
videoPlayer = lib.mkPackageOption pkgs "video player" {default = ["celluloid"];};
webBrowser = lib.mkPackageOption pkgs "web browser" {default = ["firefox"];};
};
desktop = {
autoSuspend = lib.mkOption {
description = "Whether to autosuspend on idle.";
default = cfg.desktop.hyprland.enable || cfg.desktop.sway.enable;
type = lib.types.bool;
};
hyprland = {
enable = lib.mkOption {
description = "Hyprland with full desktop session components.";
default = osConfig.ar.desktop.hyprland.enable;
type = lib.types.bool;
};
laptopMonitors = lib.mkOption {
description = "List of internal laptop monitors.";
default = [];
type = lib.types.listOf lib.types.str;
};
monitors = lib.mkOption {
description = "List of external monitors.";
default = [];
type = lib.types.listOf lib.types.str;
};
tabletMode = {
enable = lib.mkEnableOption "Tablet mode for hyprland.";
switches = lib.mkOption {
description = "Switches to activate tablet mode when toggled.";
default = [];
type = lib.types.listOf lib.types.str;
};
};
};
sway = {
enable = lib.mkOption {
description = "Sway with full desktop session components.";
default = osConfig.ar.desktop.sway.enable;
type = lib.types.bool;
};
};
windowManagerBinds = lib.mkOption {
description = "Default binds for window management.";
default = {
Down = "down";
Left = "left";
Right = "right";
Up = "up";
H = "left";
J = "down";
K = "up";
L = "right";
};
type = lib.types.attrs;
};
};
2024-08-19 19:18:41 -04:00
laptopMode = lib.mkOption {
description = "Enable laptop configuration.";
default = osConfig.ar.laptopMode;
type = lib.types.bool;
};
services = {
easyeffects = {
enable = lib.mkEnableOption "EasyEffects user service.";
preset = lib.mkOption {
description = "Name of preset to start with.";
default = "";
type = lib.types.str;
};
};
gammastep.enable = lib.mkEnableOption "Gammastep redshift daemon.";
mako.enable = lib.mkEnableOption "Mako notification daemon.";
mpd = {
enable = lib.mkEnableOption "MPD user service.";
musicDirectory = lib.mkOption {
description = "Name of music directory";
default = config.xdg.userDirs.music;
type = lib.types.str;
};
};
pipewire-inhibit.enable = lib.mkEnableOption "Inhibit idle when audio is playing with Pipewire.";
randomWallpaper.enable = lib.mkEnableOption "Lightweight swaybg-based random wallpaper daemon.";
swayidle.enable = lib.mkEnableOption "Swayidle idle daemon.";
swayosd.enable = lib.mkEnableOption "OSD for brightness and volume keys.";
waybar.enable = lib.mkEnableOption "Waybar wayland panel.";
};
2024-06-28 21:07:20 -04:00
theme = {
2024-06-28 21:07:20 -04:00
enable = lib.mkEnableOption "Gtk, Qt, and application colors.";
2024-08-15 18:31:07 -04:00
borders = {
radius = lib.mkOption {
description = "Global border radius.";
default = 10;
type = lib.types.int;
};
};
gtk.hideTitleBar = lib.mkOption {
description = "Whether to hide GTK3/4 titlebars (useful for some window managers).";
default = false;
type = lib.types.bool;
};
};
};
}