diff --git a/flake.lock b/flake.lock index 191aadc..1d87ec2 100644 --- a/flake.lock +++ b/flake.lock @@ -16,69 +16,34 @@ "type": "github" } }, - "base16": { - "inputs": { - "fromYaml": "fromYaml" - }, + "catppuccin": { "locked": { - "lastModified": 1708890466, - "narHash": "sha256-LlrC09LoPi8OPYOGPXegD72v+//VapgAqhbOFS3i8sc=", - "owner": "SenchoPens", - "repo": "base16.nix", - "rev": "665b3c6748534eb766c777298721cece9453fdae", + "lastModified": 1727910534, + "narHash": "sha256-IjdGPDnBNk3r5h02kiPTKUOfn+UiKNWlhy/ozC0NgyQ=", + "owner": "catppuccin", + "repo": "nix", + "rev": "bad96d3fabf8d2e8f0bf0c2cb899a9fccf01ea03", "type": "github" }, "original": { - "owner": "SenchoPens", - "repo": "base16.nix", + "owner": "catppuccin", + "repo": "nix", "type": "github" } }, - "base16-fish": { + "catppuccin-palette": { "flake": false, "locked": { - "lastModified": 1622559957, - "narHash": "sha256-PebymhVYbL8trDVVXxCvZgc0S5VxI7I1Hv4RMSquTpA=", - "owner": "tomyun", - "repo": "base16-fish", - "rev": "2f6dd973a9075dabccd26f1cded09508180bf5fe", + "lastModified": 1726892642, + "narHash": "sha256-UJkNgvTCF/btQFIg5aqMXvDiC54iontbHJ5TEXdltE0=", + "owner": "catppuccin", + "repo": "palette", + "rev": "a52db8d9d675c4f1d3030f1b3c288a1934b019fd", "type": "github" }, "original": { - "owner": "tomyun", - "repo": "base16-fish", - "type": "github" - } - }, - "base16-helix": { - "flake": false, - "locked": { - "lastModified": 1725860795, - "narHash": "sha256-Z2o8VBPW3I+KKTSfe25kskz0EUj7MpUh8u355Z1nVsU=", - "owner": "tinted-theming", - "repo": "base16-helix", - "rev": "7f795bf75d38e0eea9fed287264067ca187b88a9", - "type": "github" - }, - "original": { - "owner": "tinted-theming", - "repo": "base16-helix", - "type": "github" - } - }, - "base16-vim": { - "flake": false, - "locked": { - "lastModified": 1716150083, - "narHash": "sha256-ZMhnNmw34ogE5rJZrjRv5MtG3WaqKd60ds2VXvT6hEc=", - "owner": "tinted-theming", - "repo": "base16-vim", - "rev": "6e955d704d046b0dc3e5c2d68a2a6eeffd2b5d3d", - "type": "github" - }, - "original": { - "owner": "tinted-theming", - "repo": "base16-vim", + "owner": "catppuccin", + "repo": "palette", "type": "github" } }, @@ -189,22 +154,6 @@ "type": "github" } }, - "flake-compat_4": { - "flake": false, - "locked": { - "lastModified": 1673956053, - "narHash": "sha256-4gtG9iQuiKITOjNQQeQIpoIB6b16fm+504Ch3sNKLd8=", - "owner": "edolstra", - "repo": "flake-compat", - "rev": "35bb57c0c8d8b62bbfd284272c928ceb64ddbde9", - "type": "github" - }, - "original": { - "owner": "edolstra", - "repo": "flake-compat", - "type": "github" - } - }, "flake-parts": { "inputs": { "nixpkgs-lib": [ @@ -295,27 +244,6 @@ "type": "github" } }, - "flake-utils_4": { - "inputs": { - "systems": [ - "stylix", - "systems" - ] - }, - "locked": { - "lastModified": 1710146030, - "narHash": "sha256-SZ5L6eA7HJ/nmkzGG7/ISclqe6oZdOZTNoesiInkXPQ=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "b1d9ab70662946ef0850d488da1c9019f3a9752a", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, "flakey-profile": { "locked": { "lastModified": 1712898590, @@ -331,22 +259,6 @@ "type": "github" } }, - "fromYaml": { - "flake": false, - "locked": { - "lastModified": 1689549921, - "narHash": "sha256-iX0pk/uB019TdBGlaJEWvBCfydT6sRq+eDcGPifVsCM=", - "owner": "SenchoPens", - "repo": "fromYaml", - "rev": "11fbbbfb32e3289d3c631e0134a23854e7865c84", - "type": "github" - }, - "original": { - "owner": "SenchoPens", - "repo": "fromYaml", - "type": "github" - } - }, "gitignore": { "inputs": { "nixpkgs": [ @@ -391,23 +303,6 @@ "type": "github" } }, - "gnome-shell": { - "flake": false, - "locked": { - "lastModified": 1713702291, - "narHash": "sha256-zYP1ehjtcV8fo+c+JFfkAqktZ384Y+y779fzmR9lQAU=", - "owner": "GNOME", - "repo": "gnome-shell", - "rev": "0d0aadf013f78a7f7f1dc984d0d812971864b934", - "type": "github" - }, - "original": { - "owner": "GNOME", - "ref": "46.1", - "repo": "gnome-shell", - "type": "github" - } - }, "home-manager": { "inputs": { "nixpkgs": [ @@ -755,6 +650,8 @@ }, "root": { "inputs": { + "catppuccin": "catppuccin", + "catppuccin-palette": "catppuccin-palette", "colmena": "colmena", "home-manager": "home-manager", "lanzaboote": "lanzaboote", @@ -765,8 +662,7 @@ "nixpkgs": "nixpkgs", "nur": "nur", "ripgrep-all": "ripgrep-all", - "rust-overlay": "rust-overlay", - "stylix": "stylix" + "rust-overlay": "rust-overlay" } }, "rust-overlay": { @@ -805,40 +701,6 @@ "type": "github" } }, - "stylix": { - "inputs": { - "base16": "base16", - "base16-fish": "base16-fish", - "base16-helix": "base16-helix", - "base16-vim": "base16-vim", - "flake-compat": "flake-compat_4", - "flake-utils": "flake-utils_4", - "gnome-shell": "gnome-shell", - "home-manager": [ - "home-manager" - ], - "nixpkgs": [ - "nixpkgs" - ], - "systems": "systems_3", - "tinted-foot": "tinted-foot", - "tinted-kitty": "tinted-kitty", - "tinted-tmux": "tinted-tmux" - }, - "locked": { - "lastModified": 1727723275, - "narHash": "sha256-k4HrG8TJQ0RqDS1tlDz71kvWFBNQ7qZI9T5Z0qLR85Y=", - "owner": "danth", - "repo": "stylix", - "rev": "e7e97059776da7e34b739415a7bc8f80f606b803", - "type": "github" - }, - "original": { - "owner": "danth", - "repo": "stylix", - "type": "github" - } - }, "systems": { "locked": { "lastModified": 1681028828, @@ -869,69 +731,6 @@ "type": "github" } }, - "systems_3": { - "locked": { - "lastModified": 1681028828, - "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", - "owner": "nix-systems", - "repo": "default", - "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", - "type": "github" - }, - "original": { - "owner": "nix-systems", - "repo": "default", - "type": "github" - } - }, - "tinted-foot": { - "flake": false, - "locked": { - "lastModified": 1696725948, - "narHash": "sha256-65bz2bUL/yzZ1c8/GQASnoiGwaF8DczlxJtzik1c0AU=", - "owner": "tinted-theming", - "repo": "tinted-foot", - "rev": "eedbcfa30de0a4baa03e99f5e3ceb5535c2755ce", - "type": "github" - }, - "original": { - "owner": "tinted-theming", - "repo": "tinted-foot", - "type": "github" - } - }, - "tinted-kitty": { - "flake": false, - "locked": { - "lastModified": 1665001328, - "narHash": "sha256-aRaizTYPpuWEcvoYE9U+YRX+Wsc8+iG0guQJbvxEdJY=", - "owner": "tinted-theming", - "repo": "tinted-kitty", - "rev": "06bb401fa9a0ffb84365905ffbb959ae5bf40805", - "type": "github" - }, - "original": { - "owner": "tinted-theming", - "repo": "tinted-kitty", - "type": "github" - } - }, - "tinted-tmux": { - "flake": false, - "locked": { - "lastModified": 1696725902, - "narHash": "sha256-wDPg5elZPcQpu7Df0lI5O8Jv4A3T6jUQIVg63KDU+3Q=", - "owner": "tinted-theming", - "repo": "tinted-tmux", - "rev": "c02050bebb60dbb20cb433cd4d8ce668ecc11ba7", - "type": "github" - }, - "original": { - "owner": "tinted-theming", - "repo": "tinted-tmux", - "type": "github" - } - }, "xwayland-satellite-stable": { "flake": false, "locked": { diff --git a/flake.nix b/flake.nix index 8e9c150..6c3014c 100644 --- a/flake.nix +++ b/flake.nix @@ -27,10 +27,10 @@ inputs.nixpkgs.follows = "nixpkgs"; }; - stylix = { - url = "github:danth/stylix"; - inputs.nixpkgs.follows = "nixpkgs"; - inputs.home-manager.follows = "home-manager"; + catppuccin.url = "github:catppuccin/nix"; + catppuccin-palette = { + url = "github:catppuccin/palette"; + flake = false; }; nix-index-database = { diff --git a/home/config/nil/bar.nix b/home/config/nil/bar.nix index 7bbd4e3..6399e53 100644 --- a/home/config/nil/bar.nix +++ b/home/config/nil/bar.nix @@ -26,66 +26,65 @@ in lib.mkIf (osConfig.hardware.graphics.enable or false) { sndioSupport = false; }; - style = pkgs.writeText "waybar-style.css" - (with config.lib.stylix.colors.withHashtag; '' - * { - font: 600 12pt sans-serif; - } + style = '' + * { + font: 600 12pt sans-serif; + } - window, tooltip { - background: ${base00}; - color: ${base05}; - } + window, tooltip { + background: @base; + color: @text; + } - tooltip { - border-color: ${base0D}; - } + tooltip { + border-color: @blue; + } - #tray, #taskbar, .modules-center, .modules-right { - padding: 0 3mm; - } + #tray, #taskbar, .modules-center, .modules-right { + padding: 0 3mm; + } - #tray image { - padding: 0 1.5mm; - } + #tray image { + padding: 0 1.5mm; + } - #taskbar button { - padding: 0 1.5mm; - } + #taskbar button { + padding: 0 1.5mm; + } - .modules-right label.module { - padding: 1.5mm 3mm; - min-width: 5mm; - } + .modules-right label.module { + padding: 1.5mm 3mm; + min-width: 5mm; + } - #battery.warning { - color: ${yellow}; - } + #battery.warning { + color: @yellow; + } - #battery.critical { - color: ${red}; - } + #battery.critical { + color: @red; + } - #temperature.critical { - color: ${red}; - } + #temperature.critical { + color: @red; + } - #idle_inhibitor.activated { - color: ${yellow}; - } + #idle_inhibitor.activated { + color: @yellow; + } - #pulseaudio.sink.muted { - color: ${base03}; - } + #pulseaudio.sink.muted { + color: @surface1; + } - #pulseaudio.source { - color: ${yellow}; - } + #pulseaudio.source { + color: @yellow; + } - #pulseaudio.source.source-muted { - color: ${base03}; - } - '') |> lib.mkForce; + #pulseaudio.source.source-muted { + color: @surface1; + } + ''; settings = { main = { diff --git a/home/config/nil/desktop.nix b/home/config/nil/desktop.nix index 4f78a91..dd50903 100644 --- a/home/config/nil/desktop.nix +++ b/home/config/nil/desktop.nix @@ -1,4 +1,4 @@ -{ ... }: { config, lib, pkgs, ... }@args: +{ self, ... }: { config, lib, pkgs, ... }@args: let osConfig = args.osConfig or { }; @@ -20,7 +20,6 @@ let name = "fuzzel-askpass"; text = '' exec ${fuzzel} \ - --font=monospace \ --prompt="󰣀 " \ --password \ --lines=0 \ @@ -41,10 +40,20 @@ in lib.mkIf (osConfig.hardware.graphics.enable or false) { simple-scan ]; + gtk = { + enable = true; + catppuccin = { + enable = true; + gnomeShellTheme = true; + icon.enable = true; + }; + }; + programs.fuzzel = { enable = true; settings = { main = { + font = "monospace:size=10"; prompt = "❯ "; }; }; @@ -92,11 +101,11 @@ in lib.mkIf (osConfig.hardware.graphics.enable or false) { width = 1; active = { - color = config.lib.stylix.colors.withHashtag.base0D; + color = self.lib.catppuccin.mocha.colors.blue.hex; }; inactive = { - color = config.lib.stylix.colors.withHashtag.base03; + color = self.lib.catppuccin.mocha.colors.surface1.hex; }; }; diff --git a/home/config/nil/editor.nix b/home/config/nil/editor.nix index 010e419..fe480fb 100644 --- a/home/config/nil/editor.nix +++ b/home/config/nil/editor.nix @@ -2,9 +2,8 @@ programs.helix = { enable = true; defaultEditor = true; + catppuccin.useItalics = true; settings = { - theme = lib.mkForce "catppuccin_mocha"; - editor = { rulers = [ 80 120 ]; diff --git a/home/config/nil/founts.nix b/home/config/nil/founts.nix index 058a2ba..e85fb10 100644 --- a/home/config/nil/founts.nix +++ b/home/config/nil/founts.nix @@ -1,6 +1,16 @@ { self, ... }: { config, lib, pkgs, ... }@args: let osConfig = args.osConfig or { }; + + iosevka = pkgs.iosevka.override { + set = "-idiosyn-sans-term"; + privateBuildPlan = import ./iosevka.nix // { + family = "idiosyn sans term"; + spacing = "term"; + }; + }; + + nerdfonts = pkgs.nerdfonts.override { fonts = [ "NerdFontsSymbolsOnly" ]; }; in lib.mkIf (osConfig.hardware.graphics.enable or false) { fonts.fontconfig = { enable = true; @@ -32,48 +42,15 @@ in lib.mkIf (osConfig.hardware.graphics.enable or false) { home.packages = with pkgs; [ fira-code + iosevka julia-mono lato mplus-outline-fonts.githubRelease - (nerdfonts.override { fonts = [ "NerdFontsSymbolsOnly" ]; }) + nerdfonts noto-fonts noto-fonts-color-emoji unifont ]; - stylix.fonts = { - sansSerif = { - package = pkgs.lato; - name = "sans-serif"; - }; - - serif = { - package = pkgs.noto-fonts; - name = "serif"; - }; - - monospace = { - package = pkgs.iosevka.override { - set = "-idiosyn-sans-term"; - privateBuildPlan = import ./iosevka.nix // { - family = "idiosyn sans term"; - spacing = "term"; - }; - }; - - name = "monospace"; - }; - - emoji = { - package = pkgs.noto-fonts-color-emoji; - name = "emoji"; - }; - - sizes = { - terminal = 11; - popups = 13; - }; - }; - xdg.configFile."fontconfig/conf.d/80-fira-code.conf".source = ./fira-code.xml; } diff --git a/home/config/nil/home.nix b/home/config/nil/home.nix index ff1dc58..7d0076c 100644 --- a/home/config/nil/home.nix +++ b/home/config/nil/home.nix @@ -1,4 +1,4 @@ -{ self, nur, stylix, nix-index-database, niri, ripgrep-all, ... }: { config, lib, pkgs, ... }@args: +{ self, nur, catppuccin, nix-index-database, niri, ripgrep-all, ... }: { config, lib, pkgs, ... }@args: let osConfig = args.osConfig or { }; in { @@ -7,14 +7,11 @@ in { self.homeModules.greedy self.homeModules.locale-en_EU nix-index-database.hmModules.nix-index - stylix.homeManagerModules.stylix - + catppuccin.homeManagerModules.catppuccin niri.homeModules.config - niri.homeModules.stylix ] ++ self.lib.mods [ ./gammarelay.nix ./founts.nix - ./stylix.nix ./editor.nix ./desktop.nix ./bar.nix @@ -30,6 +27,11 @@ in { home.stateVersion = "24.11"; home.enableNixpkgsReleaseCheck = false; + catppuccin = { + enable = true; + pointerCursor.enable = true; + }; + home.packages = with pkgs; [ # Terminfo kitty.terminfo @@ -111,30 +113,13 @@ in { }; }; - programs.bat = { - enable = true; - config = { - theme = lib.mkForce "Catppuccin Mocha"; - }; - - themes."Catppuccin Mocha" = { - src = pkgs.fetchFromGitHub { - owner = "catppuccin"; - repo = "bat"; - rev = "d3feec47b16a8e99eabb34cdfbaa115541d374fc"; - hash = "sha256-s0CHTihXlBMCKmbBBb8dUhfgOOQu9PBCQ+uviy7o47w="; - }; - - file = "themes/Catppuccin Mocha.tmTheme"; - }; - }; + programs.bat.enable = true; programs.bottom = { enable = true; settings.flags = { group = true; battery = true; - color = "gruvbox"; mem_as_value = true; network_use_binary_prefix = true; network_use_bytes = true; diff --git a/home/config/nil/stylix.nix b/home/config/nil/stylix.nix deleted file mode 100644 index 58347a3..0000000 --- a/home/config/nil/stylix.nix +++ /dev/null @@ -1,12 +0,0 @@ -{ ... }: { config, lib, pkgs, ... }@args: -let - osConfig = args.osConfig or { }; -in { - stylix = { - enable = true; - base16Scheme = "${pkgs.base16-schemes}/share/themes/catppuccin-mocha.yaml"; - image = config.lib.stylix.pixel "base00"; - - targets.gtk.enable = osConfig.hardware.graphics.enable or false; - }; -} diff --git a/home/config/nil/terminal.nix b/home/config/nil/terminal.nix index f5a3908..00d1331 100644 --- a/home/config/nil/terminal.nix +++ b/home/config/nil/terminal.nix @@ -10,7 +10,6 @@ in lib.mkIf (osConfig.hardware.graphics.enable or false) { programs.kitty = { enable = true; - themeFile = "Catppuccin-Mocha"; settings = { disable_ligatures = "cursor"; diff --git a/lib/catppuccin.nix b/lib/catppuccin.nix new file mode 100644 index 0000000..c57048f --- /dev/null +++ b/lib/catppuccin.nix @@ -0,0 +1,5 @@ +{ catppuccin-palette, ... }: + +catppuccin-palette + /palette.json +|> builtins.readFile +|> builtins.fromJSON diff --git a/nixos/module/default.nix b/nixos/module/default.nix index d9a7f88..27c4c2a 100644 --- a/nixos/module/default.nix +++ b/nixos/module/default.nix @@ -1,5 +1,7 @@ -{ self, ... }: { config, lib, pkgs, ... }: { - imports = with self.nixosModules; [ +{ self, catppuccin, ... }: { config, lib, pkgs, ... }: { + imports = [ + catppuccin.nixosModules.catppuccin + ] ++ (with self.nixosModules; [ broken btrfs clusters @@ -16,11 +18,13 @@ security users zram - ]; + ]); #boot.initrd.systemd.enable = true; boot.tmp.useTmpfs = true; + catppuccin.enable = true; + documentation = { dev.enable = true; doc.enable = false;