aboutsummaryrefslogtreecommitdiff
path: root/home/rices/schrottkatze/niri.nix
diff options
context:
space:
mode:
authorNatasha Moongrave <natasha@256phi.eu>2026-04-10 19:20:58 +0200
committerNatasha Moongrave <natasha@256phi.eu>2026-04-10 19:20:58 +0200
commitadcc6ca839c4780a8adb82de712ec3c9e4da33f3 (patch)
treecafb7b744316ad79aef2bb2c899f920c4ae2cc83 /home/rices/schrottkatze/niri.nix
parenta414126dbda913dcc33d5f9546a9f99859d1557f (diff)
parent84d39cf904e7008434c1e5ed8257cf09b1875bea (diff)
Merge branch 'schrott-extract-rice'
Diffstat (limited to 'home/rices/schrottkatze/niri.nix')
-rw-r--r--home/rices/schrottkatze/niri.nix40
1 files changed, 40 insertions, 0 deletions
diff --git a/home/rices/schrottkatze/niri.nix b/home/rices/schrottkatze/niri.nix
new file mode 100644
index 0000000..32e145f
--- /dev/null
+++ b/home/rices/schrottkatze/niri.nix
@@ -0,0 +1,40 @@
+# this file must only be saved via autosave due to the formatter.
+# else it will be ugly
+{
+ pkgs,
+ lib,
+ ...
+}: {
+ home.packages = with pkgs; [
+ zenity
+ xwayland-satellite
+ swaybg
+ ];
+
+ xdg.configFile."niri/live.kdl".text = "";
+
+ home.file."config" = let
+ kdlfiles =
+ lib.mapAttrsToList
+ (filename: _value: "include \"${./niri/kdl}/${filename}\"")
+ (lib.filterAttrs (key: value: value == "regular") (builtins.readDir ./niri/kdl));
+ startups =
+ map (it: "spawn-at-startup ${it}")
+ (map (lib.concatStringsSep " ")
+ (map (map (word: "\"${word}\""))
+ [
+ ["eww" "open-many" "topBar" "bottomBar"]
+ ["sh" "-c" "sleep 1 && swaybg -o eDP-1 -i ${../../../assets/wallpapers/insert_coin.jpeg} -m fill"]
+ ["touch" ".config/niri/live.kdl"]
+ ]));
+ other = [
+ "include \"live.kdl\""
+ "output \"eDP-1\" { scale 1.1; }"
+ "animations { window-open { duration-ms 3000; curve \"linear\"; custom-shader r\"\n${builtins.readFile ./niri/shaders/arc.frag}\";};}"
+ "binds {Mod+Shift+I { spawn \"${./niri/scripts/cpdate.sh}\"; }; }"
+ ];
+ in {
+ target = ".config/niri/config.kdl";
+ text = lib.concatLines (startups ++ kdlfiles ++ other);
+ };
+}