This commit is contained in:
Peritia 2026-02-12 15:32:45 +01:00
parent b6b87d5aed
commit 9c72a71585
3546 changed files with 18655 additions and 0 deletions

View file

@ -0,0 +1,66 @@
{
config,
lib,
nixosVista,
...
}: let
cfg = nixosVista.hyprland.startup;
root = nixosVista;
############################################################
# Default Preset (Context Aware)
############################################################
defaultExecOnce = [
"nm-applet"
"waybar"
"hyprpaper"
# "/usr/lib/polkit-gnome/polkit-gnome-authentication-agent-1"
"$HOME/.config/eww/start.sh"
];
defaultExec = [];
minimalExecOnce = [];
minimalExec = [];
############################################################
# Select preset
############################################################
presetExecOnce =
if cfg.preset == "default"
then defaultExecOnce
else if cfg.preset == "minimal"
then minimalExecOnce
else [];
presetExec =
if cfg.preset == "default"
then defaultExec
else if cfg.preset == "minimal"
then minimalExec
else [];
############################################################
# Merge user extras
############################################################
finalExecOnce = presetExecOnce ++ cfg.extraExecOnce;
finalExec = presetExec ++ cfg.extraExec;
execOnceLines = map (cmd: "exec-once = ${cmd}") finalExecOnce;
execLines = map (cmd: "exec = ${cmd}") finalExec;
allLines = execOnceLines ++ execLines;
in {
config = lib.mkIf (nixosVista.enable && allLines != []) {
nixosVista.hyprland.fragments.startup = ''
############################################################
# Startup Programs
############################################################
${lib.concatStringsSep "\n" allLines}
'';
};
}