From 3182e42192541498680e3367e27071884e2a901c Mon Sep 17 00:00:00 2001 From: moons14 Date: Wed, 29 Oct 2025 21:33:39 +0900 Subject: [PATCH] stylix --- flake.nix | 4 ++++ modules/core/default.nix | 3 ++- modules/core/stylix.nix | 13 +++++++++++++ modules/home/stylix.nix | 11 +++++++++++ modules/home/wallpaper/swww.sh | 1 + profiles/gui.nix | 2 ++ 6 files changed, 33 insertions(+), 1 deletion(-) create mode 100644 modules/core/stylix.nix create mode 100644 modules/home/stylix.nix diff --git a/flake.nix b/flake.nix index 5e67bf5..72f7dba 100644 --- a/flake.nix +++ b/flake.nix @@ -22,6 +22,10 @@ inputs.nixpkgs.follows = "nixpkgs"; inputs.quickshell.follows = "quickshell"; }; + stylix = { + url = "github:nix-community/stylix"; + inputs.nixpkgs.follows = "nixpkgs"; + }; }; outputs = inputs@{ self, nixpkgs, nixpkgs-unstable, nixos-hardware, home-manager, ...}: diff --git a/modules/core/default.nix b/modules/core/default.nix index 9c9b6e8..df2814a 100644 --- a/modules/core/default.nix +++ b/modules/core/default.nix @@ -1,4 +1,4 @@ -{ ... }: +{ inputs, ... }: { imports = [ ./boot.nix @@ -12,5 +12,6 @@ ./system.nix ./user.nix ./xserver.nix + inputs.stylix.nixosModules.stylix ]; } diff --git a/modules/core/stylix.nix b/modules/core/stylix.nix new file mode 100644 index 0000000..ff54f05 --- /dev/null +++ b/modules/core/stylix.nix @@ -0,0 +1,13 @@ +{ pkgs, ... }: +{ + stylix = { + enable = true; + polarity = "dark"; + opacity.terminal = 1.0; + cursor = { + package = pkgs.bibata-cursors; + name = "Bibata-Modern-Ice"; + size = 24; + }; + }; +} \ No newline at end of file diff --git a/modules/home/stylix.nix b/modules/home/stylix.nix new file mode 100644 index 0000000..54e652b --- /dev/null +++ b/modules/home/stylix.nix @@ -0,0 +1,11 @@ +{ ... }: +{ + stylix.targets = { + ghostty.enable = false; + noctalia.enable = false; + qt = { + enable = true; + platform = "qtct"; + }; + }; +} diff --git a/modules/home/wallpaper/swww.sh b/modules/home/wallpaper/swww.sh index a93d374..0ff944e 100644 --- a/modules/home/wallpaper/swww.sh +++ b/modules/home/wallpaper/swww.sh @@ -7,5 +7,6 @@ mapfile -t files < <(find "$WALLPAPERS_DIR" -type f 2>/dev/null) file="$(printf '%s\n' "${files[@]}" | shuf -n 1)" +echo file: "$file" exec swww img "$file" --transition-type grow --transition-step 90 diff --git a/profiles/gui.nix b/profiles/gui.nix index b54e283..6540fc5 100644 --- a/profiles/gui.nix +++ b/profiles/gui.nix @@ -6,6 +6,7 @@ ./../modules/core/hyprland.nix ./../modules/core/greetd.nix ./../modules/core/noctalia.nix + ./../modules/core/stylix.nix ]; home-manager.users.moons.imports = [ @@ -17,5 +18,6 @@ ./../modules/home/avatar.nix ./../modules/home/ghostty ./../modules/home/wallpaper + ./../modules/home/stylix.nix ]; } \ No newline at end of file