├── assets ├── logo.png └── previews │ ├── latte.webp │ ├── mocha.webp │ ├── frappe.webp │ ├── preview.webp │ └── macchiato.webp ├── docs ├── public │ └── favicon.png ├── content.config.ts ├── pages │ ├── changelog.astro │ └── options │ │ └── [version] │ │ └── [type] │ │ └── [module].astro ├── content │ └── docs │ │ ├── Getting Started │ │ ├── index.md │ │ ├── stable.mdx │ │ └── flakes.mdx │ │ ├── index.md │ │ ├── FAQ.md │ │ └── Contributing.md └── data │ ├── options.ts │ ├── v1.2-nixos-options.json │ └── v1.1-nixos-options.json ├── pkgs ├── catppuccinInstallHook │ ├── package.nix │ └── script.sh ├── k9s │ └── package.nix ├── aerc │ └── package.nix ├── lazygit │ └── package.nix ├── wezterm │ └── package.nix ├── wlogout │ └── package.nix ├── palette │ └── package.nix ├── delta │ └── package.nix ├── qutebrowser │ └── package.nix ├── rofi │ └── package.nix ├── spotify-player │ └── package.nix ├── alacritty │ └── package.nix ├── gitea │ └── package.nix ├── grub │ └── package.nix ├── vscode-icons │ └── package.nix ├── zed │ └── package.nix ├── hyprlock │ └── package.nix ├── kvantum │ └── package.nix ├── fetchCatppuccinPort │ └── package.nix ├── tmux │ └── package.nix ├── fcitx5 │ └── package.nix ├── plymouth │ └── package.nix ├── nvim │ └── package.nix ├── firefox │ ├── package.nix │ └── write-themes-to-json.patch ├── whiskers │ └── package.nix ├── swaync │ └── package.nix ├── cursors │ └── package.nix ├── catwalk │ └── package.nix ├── buildCatppuccinPort │ └── package.nix ├── vscode │ └── package.nix ├── sddm │ └── package.nix └── paws.py ├── renovate.json ├── .prettierignore ├── dev ├── README.md ├── update-docs-data.sh ├── flake.lock └── flake.nix ├── modules ├── nixos │ ├── default.nix │ ├── all-modules.nix │ ├── limine.nix │ ├── plymouth.nix │ ├── grub.nix │ ├── fcitx5.nix │ ├── tty.nix │ ├── gtk.nix │ ├── cursors.nix │ ├── gitea.nix │ └── sddm.nix ├── home-manager │ ├── default.nix │ ├── vivid.nix │ ├── sioyek.nix │ ├── nushell.nix │ ├── mangohud.nix │ ├── lsd.nix │ ├── eza.nix │ ├── kitty.nix │ ├── vicinae.nix │ ├── imv.nix │ ├── rio.nix │ ├── zellij.nix │ ├── bottom.nix │ ├── glamour.nix │ ├── polybar.nix │ ├── tofi.nix │ ├── foot.nix │ ├── gitui.nix │ ├── halloy.nix │ ├── zathura.nix │ ├── alacritty.nix │ ├── ghostty.nix │ ├── atuin.nix │ ├── newsboat.nix │ ├── sway.nix │ ├── mpv.nix │ ├── element-desktop.nix │ ├── mako.nix │ ├── bat.nix │ ├── fuzzel.nix │ ├── spotify-player.nix │ ├── starship.nix │ ├── gh-dash.nix │ ├── television.nix │ ├── delta.nix │ ├── fish.nix │ ├── obs.nix │ ├── aerc.nix │ ├── btop.nix │ ├── vesktop.nix │ ├── yazi.nix │ ├── chrome.nix │ ├── micro.nix │ ├── rofi.nix │ ├── anki.nix │ ├── swaync.nix │ ├── qutebrowser.nix │ ├── skim.nix │ ├── cava.nix │ ├── wezterm.nix │ ├── fzf.nix │ ├── hyprlock.nix │ ├── cursors.nix │ ├── hyprland.nix │ ├── helix.nix │ ├── xfce4-terminal.nix │ ├── tmux.nix │ ├── all-modules.nix │ ├── neovim.nix │ ├── thunderbird.nix │ ├── lazygit.nix │ ├── zed-editor.nix │ ├── dunst.nix │ ├── freetube.nix │ ├── wlogout.nix │ ├── k9s.nix │ ├── waybar.nix │ ├── swaylock.nix │ ├── kvantum.nix │ ├── fcitx5.nix │ ├── zsh-syntax-highlighting.nix │ ├── gtk.nix │ ├── vscode.nix │ └── firefox.nix ├── tests │ ├── nixos.nix │ └── home.nix └── global.nix ├── tsconfig.json ├── .github └── workflows │ ├── deploy-release.yml │ ├── backport.yml │ ├── format.yml │ ├── ci.yml │ ├── website.yml │ └── update-locks.yml ├── flake.lock ├── .editorconfig ├── package.json ├── LICENSE ├── shell.nix ├── default.nix ├── README.md ├── .gitignore ├── cliff.toml ├── flake.nix └── astro.config.ts /assets/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/catppuccin/nix/HEAD/assets/logo.png -------------------------------------------------------------------------------- /docs/public/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/catppuccin/nix/HEAD/docs/public/favicon.png -------------------------------------------------------------------------------- /assets/previews/latte.webp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/catppuccin/nix/HEAD/assets/previews/latte.webp -------------------------------------------------------------------------------- /assets/previews/mocha.webp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/catppuccin/nix/HEAD/assets/previews/mocha.webp -------------------------------------------------------------------------------- /assets/previews/frappe.webp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/catppuccin/nix/HEAD/assets/previews/frappe.webp -------------------------------------------------------------------------------- /assets/previews/preview.webp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/catppuccin/nix/HEAD/assets/previews/preview.webp -------------------------------------------------------------------------------- /assets/previews/macchiato.webp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/catppuccin/nix/HEAD/assets/previews/macchiato.webp -------------------------------------------------------------------------------- /pkgs/catppuccinInstallHook/package.nix: -------------------------------------------------------------------------------- 1 | { makeSetupHook }: 2 | 3 | makeSetupHook { 4 | name = "catppuccin-install-hook"; 5 | } ./script.sh 6 | -------------------------------------------------------------------------------- /pkgs/k9s/package.nix: -------------------------------------------------------------------------------- 1 | { buildCatppuccinPort }: 2 | 3 | buildCatppuccinPort { 4 | port = "k9s"; 5 | 6 | installTargets = [ "dist" ]; 7 | } 8 | -------------------------------------------------------------------------------- /pkgs/aerc/package.nix: -------------------------------------------------------------------------------- 1 | { buildCatppuccinPort }: 2 | 3 | buildCatppuccinPort { 4 | port = "aerc"; 5 | 6 | installTargets = [ "dist/" ]; 7 | } 8 | -------------------------------------------------------------------------------- /renovate.json: -------------------------------------------------------------------------------- 1 | { 2 | "$schema": "https://docs.renovatebot.com/renovate-schema.json", 3 | "extends": ["config:recommended", "schedule:weekly"] 4 | } 5 | -------------------------------------------------------------------------------- /.prettierignore: -------------------------------------------------------------------------------- 1 | pnpm-lock.yaml 2 | 3 | # Nix-generated data files 4 | docs/data/*.json 5 | pkgs/sources.json 6 | 7 | # Generated by git-cliff 8 | CHANGELOG.md 9 | -------------------------------------------------------------------------------- /dev/README.md: -------------------------------------------------------------------------------- 1 | > [!WARNING] 2 | > This is using features from Nix >= 2.26. 3 | > **_It will not properly evaluate on versions prior to 2.26 (Lix included!)_**. 4 | -------------------------------------------------------------------------------- /pkgs/lazygit/package.nix: -------------------------------------------------------------------------------- 1 | { buildCatppuccinPort }: 2 | 3 | buildCatppuccinPort { 4 | port = "lazygit"; 5 | 6 | installTargets = [ "themes-mergable" ]; 7 | } 8 | -------------------------------------------------------------------------------- /pkgs/wezterm/package.nix: -------------------------------------------------------------------------------- 1 | { buildCatppuccinPort }: 2 | 3 | buildCatppuccinPort { 4 | port = "wezterm"; 5 | 6 | installTargets = [ 7 | "dist" 8 | "plugin" 9 | ]; 10 | } 11 | -------------------------------------------------------------------------------- /pkgs/wlogout/package.nix: -------------------------------------------------------------------------------- 1 | { buildCatppuccinPort }: 2 | 3 | buildCatppuccinPort { 4 | port = "wlogout"; 5 | 6 | installTargets = [ 7 | "themes" 8 | "icons" 9 | ]; 10 | } 11 | -------------------------------------------------------------------------------- /pkgs/palette/package.nix: -------------------------------------------------------------------------------- 1 | { buildCatppuccinPort }: 2 | 3 | buildCatppuccinPort { 4 | port = "palette"; 5 | 6 | installTargets = [ 7 | "README.md" 8 | "palette.json" 9 | ]; 10 | } 11 | -------------------------------------------------------------------------------- /pkgs/delta/package.nix: -------------------------------------------------------------------------------- 1 | { buildCatppuccinPort }: 2 | 3 | buildCatppuccinPort { 4 | port = "delta"; 5 | 6 | installTargets = [ 7 | "catppuccin.gitconfig" 8 | "README.md" 9 | ]; 10 | } 11 | -------------------------------------------------------------------------------- /pkgs/qutebrowser/package.nix: -------------------------------------------------------------------------------- 1 | { buildCatppuccinPort }: 2 | 3 | buildCatppuccinPort { 4 | port = "qutebrowser"; 5 | 6 | installTargets = [ 7 | "setup.py" 8 | "__init__.py" 9 | ]; 10 | } 11 | -------------------------------------------------------------------------------- /pkgs/rofi/package.nix: -------------------------------------------------------------------------------- 1 | { buildCatppuccinPort }: 2 | 3 | buildCatppuccinPort { 4 | port = "rofi"; 5 | 6 | installTargets = [ 7 | "themes" 8 | "catppuccin-default.rasi" 9 | ]; 10 | } 11 | -------------------------------------------------------------------------------- /pkgs/spotify-player/package.nix: -------------------------------------------------------------------------------- 1 | { buildCatppuccinPort }: 2 | 3 | buildCatppuccinPort { 4 | port = "spotify-player"; 5 | 6 | installTargets = [ 7 | "theme.toml" 8 | "README.md" 9 | ]; 10 | } 11 | -------------------------------------------------------------------------------- /modules/nixos/default.nix: -------------------------------------------------------------------------------- 1 | { lib, ... }: 2 | 3 | { 4 | _class = "nixos"; 5 | 6 | imports = [ 7 | (lib.modules.importApply ../global.nix { catppuccinModules = import ./all-modules.nix; }) 8 | ]; 9 | } 10 | -------------------------------------------------------------------------------- /modules/home-manager/default.nix: -------------------------------------------------------------------------------- 1 | { lib, ... }: 2 | 3 | { 4 | _class = "homeManager"; 5 | 6 | imports = [ 7 | (lib.modules.importApply ../global.nix { catppuccinModules = import ./all-modules.nix; }) 8 | ]; 9 | } 10 | -------------------------------------------------------------------------------- /tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "astro/tsconfigs/base", 3 | "include": [".astro/types.d.ts", "**/*"], 4 | "exclude": ["dist"], 5 | "compilerOptions": { 6 | "paths": { 7 | "@data/*": ["docs/data/*"] 8 | } 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /pkgs/alacritty/package.nix: -------------------------------------------------------------------------------- 1 | { buildCatppuccinPort }: 2 | 3 | buildCatppuccinPort { 4 | port = "alacritty"; 5 | 6 | dontCatppuccinInstall = true; 7 | 8 | postInstall = '' 9 | mkdir -p $out 10 | mv *.toml $out/ 11 | ''; 12 | } 13 | -------------------------------------------------------------------------------- /pkgs/gitea/package.nix: -------------------------------------------------------------------------------- 1 | { fetchzip }: 2 | fetchzip { 3 | url = "https://github.com/catppuccin/gitea/releases/download/v1.0.2/catppuccin-gitea.tar.gz"; 4 | hash = "sha256-rZHLORwLUfIFcB6K9yhrzr+UwdPNQVSadsw6rg8Q7gs="; 5 | stripRoot = false; 6 | } 7 | -------------------------------------------------------------------------------- /modules/nixos/all-modules.nix: -------------------------------------------------------------------------------- 1 | [ 2 | # keep-sorted start 3 | ./cursors.nix 4 | ./fcitx5.nix 5 | ./gitea.nix 6 | ./grub.nix 7 | ./gtk.nix 8 | ./limine.nix 9 | ./plymouth.nix 10 | ./sddm.nix 11 | ./tty.nix 12 | # keep-sorted end 13 | ] 14 | -------------------------------------------------------------------------------- /pkgs/grub/package.nix: -------------------------------------------------------------------------------- 1 | { buildCatppuccinPort }: 2 | 3 | buildCatppuccinPort { 4 | port = "grub"; 5 | 6 | dontCatppuccinInstall = true; 7 | 8 | postInstall = '' 9 | mkdir -p $out/share/grub 10 | mv src $out/share/grub/themes 11 | ''; 12 | } 13 | -------------------------------------------------------------------------------- /docs/content.config.ts: -------------------------------------------------------------------------------- 1 | import { defineCollection } from "astro:content"; 2 | import { docsLoader } from "@astrojs/starlight/loaders"; 3 | import { docsSchema } from "@astrojs/starlight/schema"; 4 | 5 | export const collections = { 6 | docs: defineCollection({ loader: docsLoader(), schema: docsSchema() }), 7 | }; 8 | -------------------------------------------------------------------------------- /pkgs/vscode-icons/package.nix: -------------------------------------------------------------------------------- 1 | { vscode-utils, ... }: 2 | 3 | vscode-utils.buildVscodeMarketplaceExtension { 4 | mktplcRef = { 5 | name = "catppuccin-vsc-icons"; 6 | publisher = "catppuccin"; 7 | version = "1.24.0"; 8 | hash = "sha256-2M7N4Ccw9FAaMmG36hGHi6i0i1qR+uPCSgXELAA03Xk="; 9 | }; 10 | } 11 | -------------------------------------------------------------------------------- /pkgs/zed/package.nix: -------------------------------------------------------------------------------- 1 | { buildCatppuccinPort, whiskers }: 2 | 3 | buildCatppuccinPort { 4 | port = "zed"; 5 | 6 | nativeBuildInputs = [ whiskers ]; 7 | 8 | buildPhase = '' 9 | runHook preBuild 10 | whiskers zed.tera 11 | runHook postBuild 12 | ''; 13 | 14 | installTargets = [ "themes" ]; 15 | } 16 | -------------------------------------------------------------------------------- /docs/pages/changelog.astro: -------------------------------------------------------------------------------- 1 | --- 2 | import StarlightPage from "@astrojs/starlight/components/StarlightPage.astro"; 3 | 4 | // TODO: Use Starlight's AnchorHeading components for this 5 | import { Content } from "../../CHANGELOG.md"; 6 | --- 7 | 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /pkgs/hyprlock/package.nix: -------------------------------------------------------------------------------- 1 | { buildCatppuccinPort }: 2 | 3 | buildCatppuccinPort { 4 | port = "hyprlock"; 5 | 6 | # Make sure we aren't sourcing possibly non-existent files 7 | # or overriding our own settings 8 | postPatch = '' 9 | sed -i '1,4d' hyprlock.conf 10 | ''; 11 | 12 | installTargets = [ "hyprlock.conf" ]; 13 | } 14 | -------------------------------------------------------------------------------- /modules/home-manager/vivid.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | let 4 | cfg = config.catppuccin.vivid; 5 | in 6 | { 7 | options.catppuccin.vivid = catppuccinLib.mkCatppuccinOption { name = "vivid"; }; 8 | 9 | config = lib.mkIf cfg.enable { 10 | programs.vivid.activeTheme = "catppuccin-${cfg.flavor}"; 11 | }; 12 | } 13 | -------------------------------------------------------------------------------- /pkgs/kvantum/package.nix: -------------------------------------------------------------------------------- 1 | { 2 | lib, 3 | buildCatppuccinPort, 4 | }: 5 | 6 | buildCatppuccinPort (finalAttrs: { 7 | port = "kvantum"; 8 | 9 | dontCatppuccinInstall = true; 10 | 11 | postInstall = '' 12 | mkdir -p $out/share 13 | mv themes $out/share/Kvantum/ 14 | ''; 15 | 16 | meta = { 17 | platforms = lib.platforms.linux; 18 | }; 19 | }) 20 | -------------------------------------------------------------------------------- /pkgs/fetchCatppuccinPort/package.nix: -------------------------------------------------------------------------------- 1 | { lib, fetchFromGitHub }: 2 | 3 | lib.makeOverridable ( 4 | { 5 | port, 6 | rev, 7 | hash, 8 | ... 9 | }@args: 10 | 11 | let 12 | arguments = [ "port" ]; 13 | in 14 | 15 | fetchFromGitHub ( 16 | { 17 | owner = "catppuccin"; 18 | repo = port; 19 | inherit rev hash; 20 | } 21 | // lib.removeAttrs args arguments 22 | ) 23 | ) 24 | -------------------------------------------------------------------------------- /pkgs/tmux/package.nix: -------------------------------------------------------------------------------- 1 | { 2 | lib, 3 | sources, 4 | tmuxPlugins, 5 | }: 6 | 7 | let 8 | portName = "tmux"; 9 | in 10 | 11 | tmuxPlugins.mkTmuxPlugin rec { 12 | pluginName = "catppuccin"; 13 | version = builtins.substring 0 7 src.rev; 14 | 15 | src = sources.${portName}; 16 | 17 | meta = { 18 | description = "Soothing pastel theme for ${portName}"; 19 | homepage = "https://github.com/catppuccin/${portName}"; 20 | license = lib.licenses.mit; 21 | }; 22 | } 23 | -------------------------------------------------------------------------------- /modules/home-manager/sioyek.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.sioyek; 8 | enable = cfg.enable && config.programs.sioyek.enable; 9 | in 10 | 11 | { 12 | options.catppuccin.sioyek = catppuccinLib.mkCatppuccinOption { 13 | name = "sioyek"; 14 | }; 15 | 16 | config = lib.mkIf enable { 17 | programs.sioyek.config.source = sources.sioyek + "/catppuccin-${cfg.flavor}.config"; 18 | }; 19 | } 20 | -------------------------------------------------------------------------------- /modules/home-manager/nushell.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.nushell; 8 | in 9 | 10 | { 11 | options.catppuccin.nushell = catppuccinLib.mkCatppuccinOption { name = "nushell"; }; 12 | 13 | config = lib.mkIf cfg.enable { 14 | programs.nushell = { 15 | extraConfig = lib.mkBefore '' 16 | source ${sources.nushell + "/catppuccin_${cfg.flavor}.nu"} 17 | ''; 18 | }; 19 | }; 20 | } 21 | -------------------------------------------------------------------------------- /modules/home-manager/mangohud.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | cfg = config.catppuccin.mangohud; 7 | in 8 | 9 | { 10 | options.catppuccin.mangohud = catppuccinLib.mkCatppuccinOption { name = "mangohud"; }; 11 | 12 | config = lib.mkIf cfg.enable { 13 | xdg.configFile = lib.mkIf config.programs.mangohud.enable { 14 | "MangoHud/MangoHud.conf".source = "${sources.mangohud}/${cfg.flavor}/MangoHud.conf"; 15 | }; 16 | }; 17 | } 18 | -------------------------------------------------------------------------------- /modules/nixos/limine.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { 3 | config, 4 | lib, 5 | ... 6 | }: 7 | 8 | let 9 | inherit (config.catppuccin) sources; 10 | 11 | cfg = config.catppuccin.limine; 12 | 13 | theme = sources.limine + "/catppuccin-${cfg.flavor}.conf"; 14 | in 15 | 16 | { 17 | options.catppuccin.limine = catppuccinLib.mkCatppuccinOption { name = "limine"; }; 18 | 19 | config = lib.mkIf cfg.enable { 20 | boot.loader.limine = { 21 | extraConfig = lib.fileContents theme; 22 | style.wallpapers = [ ]; 23 | }; 24 | }; 25 | } 26 | -------------------------------------------------------------------------------- /pkgs/fcitx5/package.nix: -------------------------------------------------------------------------------- 1 | { 2 | buildCatppuccinPort, 3 | lib, 4 | enableRounded ? false, 5 | }: 6 | 7 | buildCatppuccinPort { 8 | port = "fcitx5"; 9 | 10 | dontCatppuccinInstall = true; 11 | 12 | buildPhase = '' 13 | runHook preBuild 14 | 15 | ${lib.optionalString enableRounded '' 16 | patchShebangs ./enable-rounded.sh 17 | ./enable-rounded.sh 18 | ''} 19 | 20 | runHook postBuild 21 | ''; 22 | 23 | postInstall = '' 24 | mkdir -p $out/share/fcitx5 25 | mv src/ $out/share/fcitx5/themes/ 26 | ''; 27 | } 28 | -------------------------------------------------------------------------------- /.github/workflows/deploy-release.yml: -------------------------------------------------------------------------------- 1 | name: Deploy Release Docs 2 | 3 | on: 4 | push: 5 | branches: 6 | - "release-*" 7 | 8 | jobs: 9 | deploy: 10 | name: Trigger deployment 11 | 12 | permissions: 13 | actions: write 14 | 15 | runs-on: ubuntu-latest 16 | 17 | steps: 18 | - name: Dispatch website workflow 19 | env: 20 | GH_TOKEN: ${{ github.token }} 21 | REPOSITORY: ${{ github.repository }} 22 | run: | 23 | gh workflow run website.yml --repo "$REPOSITORY" --field deploy=true 24 | -------------------------------------------------------------------------------- /pkgs/plymouth/package.nix: -------------------------------------------------------------------------------- 1 | { 2 | lib, 3 | buildCatppuccinPort, 4 | }: 5 | 6 | buildCatppuccinPort (finalAttrs: { 7 | port = "plymouth"; 8 | 9 | dontCatppuccinInstall = true; 10 | 11 | postPatch = '' 12 | substituteInPlace themes/**/*.plymouth \ 13 | --replace-fail '/usr' '${placeholder "out"}' 14 | ''; 15 | 16 | postInstall = '' 17 | mkdir -p $out/share/plymouth 18 | mv themes/ $out/share/plymouth/themes/ 19 | ''; 20 | 21 | meta = { 22 | license = lib.licenses.mit; 23 | platforms = lib.platforms.linux; 24 | }; 25 | }) 26 | -------------------------------------------------------------------------------- /modules/home-manager/lsd.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.lsd; 8 | enable = cfg.enable && config.programs.lsd.enable; 9 | in 10 | 11 | { 12 | options.catppuccin.lsd = catppuccinLib.mkCatppuccinOption { name = "lsd"; }; 13 | 14 | config = lib.mkIf enable { 15 | xdg.configFile = { 16 | "lsd/colors.yaml".source = "${sources.lsd}/catppuccin-${cfg.flavor}/colors.yaml"; 17 | }; 18 | programs.lsd.settings.color.theme = "custom"; 19 | }; 20 | } 21 | -------------------------------------------------------------------------------- /docs/content/docs/Getting Started/index.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: What is catppuccin/nix? 3 | --- 4 | 5 | `catppuccin/nix` is a port of the [soothing pastel theme](https://catppuccin.com) for [Nix](https://nixos.org). 6 | 7 | To be more specific, we provide modules for NixOS and [home-manager](https://github.com/nix-community/home-manager) that enable you to quickly and easily apply the Catppuccin colorscheme across over 70 applications. Each of these are hand-crafted and specifically designed for each app by a [wonderful community of contributors](https://catppuccin.com/community/) worldwide. 8 | -------------------------------------------------------------------------------- /modules/home-manager/eza.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.eza; 8 | enable = cfg.enable && config.programs.eza.enable; 9 | in 10 | 11 | { 12 | options.catppuccin.eza = catppuccinLib.mkCatppuccinOption { 13 | name = "eza"; 14 | accentSupport = true; 15 | }; 16 | 17 | config = lib.mkIf enable { 18 | xdg.configFile = { 19 | "eza/theme.yml".source = "${sources.eza}/${cfg.flavor}/catppuccin-${cfg.flavor}-${cfg.accent}.yml"; 20 | }; 21 | }; 22 | } 23 | -------------------------------------------------------------------------------- /modules/home-manager/kitty.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | cfg = config.catppuccin.kitty; 6 | in 7 | 8 | { 9 | options.catppuccin.kitty = catppuccinLib.mkCatppuccinOption { name = "kitty"; }; 10 | 11 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 12 | from = [ 13 | "programs" 14 | "kitty" 15 | "catppuccin" 16 | ]; 17 | to = "kitty"; 18 | }; 19 | 20 | config = lib.mkIf cfg.enable { 21 | programs.kitty = { 22 | themeFile = "Catppuccin-${lib.toSentenceCase cfg.flavor}"; 23 | }; 24 | }; 25 | } 26 | -------------------------------------------------------------------------------- /modules/home-manager/vicinae.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | cfg = config.catppuccin.vicinae; 6 | in 7 | 8 | { 9 | options.catppuccin.vicinae = catppuccinLib.mkCatppuccinOption { 10 | name = "vicinae"; 11 | accentSupport = true; 12 | }; 13 | 14 | config = lib.mkIf cfg.enable { 15 | programs.vicinae = { 16 | settings = { 17 | theme = { 18 | name = "catppuccin-${cfg.flavor}"; 19 | iconTheme = "Catppuccin ${lib.toSentenceCase cfg.flavor} ${lib.toSentenceCase cfg.accent}"; 20 | }; 21 | }; 22 | }; 23 | }; 24 | } 25 | -------------------------------------------------------------------------------- /docs/content/docs/index.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: catppuccin/nix 3 | template: splash 4 | editUrl: false 5 | next: false 6 | hero: 7 | title: catppuccin/nix 8 | tagline: The soothing pastel theme - now for Nix! 9 | image: 10 | file: ../../../assets/logo.png 11 | actions: 12 | - text: Get Started 13 | link: /getting-started/ 14 | icon: right-arrow 15 | - text: View on GitHub 16 | link: https://github.com/catppuccin/nix 17 | icon: external 18 | variant: minimal 19 | - text: More about Catppuccin 20 | link: https://catppuccin.com/ 21 | icon: external 22 | variant: minimal 23 | --- 24 | -------------------------------------------------------------------------------- /modules/home-manager/imv.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.imv; 8 | in 9 | 10 | { 11 | options.catppuccin.imv = catppuccinLib.mkCatppuccinOption { name = "imv"; }; 12 | 13 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 14 | from = [ 15 | "programs" 16 | "imv" 17 | "catppuccin" 18 | ]; 19 | to = "imv"; 20 | }; 21 | 22 | config = lib.mkIf cfg.enable { 23 | programs.imv = { 24 | settings = catppuccinLib.importINI (sources.imv + "/${cfg.flavor}.config"); 25 | }; 26 | }; 27 | } 28 | -------------------------------------------------------------------------------- /modules/home-manager/rio.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.rio; 8 | in 9 | 10 | { 11 | options.catppuccin.rio = catppuccinLib.mkCatppuccinOption { name = "rio"; }; 12 | 13 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 14 | from = [ 15 | "programs" 16 | "rio" 17 | "catppuccin" 18 | ]; 19 | to = "rio"; 20 | }; 21 | 22 | config = lib.mkIf cfg.enable { 23 | programs.rio = { 24 | settings = lib.importTOML "${sources.rio}/catppuccin-${cfg.flavor}.toml"; 25 | }; 26 | }; 27 | } 28 | -------------------------------------------------------------------------------- /modules/home-manager/zellij.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | cfg = config.catppuccin.zellij; 6 | themeName = "catppuccin-${cfg.flavor}"; 7 | in 8 | 9 | { 10 | options.catppuccin.zellij = catppuccinLib.mkCatppuccinOption { name = "zellij"; }; 11 | 12 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 13 | from = [ 14 | "programs" 15 | "zellij" 16 | "catppuccin" 17 | ]; 18 | to = "zellij"; 19 | }; 20 | 21 | config = lib.mkIf cfg.enable { 22 | programs.zellij = { 23 | settings = { 24 | theme = themeName; 25 | }; 26 | }; 27 | }; 28 | } 29 | -------------------------------------------------------------------------------- /modules/home-manager/bottom.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | cfg = config.catppuccin.bottom; 7 | in 8 | 9 | { 10 | options.catppuccin.bottom = catppuccinLib.mkCatppuccinOption { name = "bottom"; }; 11 | 12 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 13 | from = [ 14 | "programs" 15 | "bottom" 16 | "catppuccin" 17 | ]; 18 | to = "bottom"; 19 | }; 20 | 21 | config = lib.mkIf cfg.enable { 22 | programs.bottom = { 23 | settings = lib.importTOML "${sources.bottom}/${cfg.flavor}.toml"; 24 | }; 25 | }; 26 | } 27 | -------------------------------------------------------------------------------- /modules/tests/nixos.nix: -------------------------------------------------------------------------------- 1 | { pkgs, ... }: 2 | 3 | { 4 | boot = { 5 | loader.grub = { 6 | enable = true; 7 | device = "nodev"; 8 | }; 9 | plymouth.enable = true; 10 | }; 11 | 12 | console.enable = true; 13 | 14 | i18n.inputMethod = { 15 | enable = true; 16 | type = "fcitx5"; 17 | }; 18 | 19 | services = { 20 | displayManager.sddm = { 21 | enable = true; 22 | package = pkgs.kdePackages.sddm; # our module/the upstream port requires the qt6 version 23 | }; 24 | forgejo.enable = true; 25 | gitea.enable = true; 26 | 27 | xserver.enable = true; # required for sddm 28 | }; 29 | } 30 | -------------------------------------------------------------------------------- /pkgs/nvim/package.nix: -------------------------------------------------------------------------------- 1 | { 2 | lib, 3 | vimUtils, 4 | sources, 5 | }: 6 | 7 | let 8 | portName = "nvim"; 9 | in 10 | 11 | vimUtils.buildVimPlugin rec { 12 | pname = "catppuccin-nvim"; 13 | version = builtins.substring 0 7 src.rev; 14 | 15 | src = sources.${portName}; 16 | 17 | nvimSkipModule = [ 18 | "catppuccin.groups.integrations.noice" 19 | "catppuccin.groups.integrations.feline" 20 | "catppuccin.lib.vim.init" 21 | ]; 22 | 23 | meta = { 24 | description = "Soothing pastel theme for ${portName}"; 25 | homepage = "https://github.com/catppuccin/${portName}"; 26 | license = lib.licenses.mit; 27 | }; 28 | } 29 | -------------------------------------------------------------------------------- /modules/home-manager/glamour.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.glamour; 8 | in 9 | 10 | { 11 | options.catppuccin.glamour = catppuccinLib.mkCatppuccinOption { name = "glamour"; }; 12 | 13 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 14 | from = [ 15 | "programs" 16 | "glamour" 17 | "catppuccin" 18 | ]; 19 | to = "glamour"; 20 | }; 21 | 22 | config = lib.mkIf cfg.enable { 23 | home.sessionVariables = { 24 | GLAMOUR_STYLE = "${sources.glamour}/catppuccin-${cfg.flavor}.json"; 25 | }; 26 | }; 27 | } 28 | -------------------------------------------------------------------------------- /modules/home-manager/polybar.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.polybar; 8 | in 9 | 10 | { 11 | options.catppuccin.polybar = catppuccinLib.mkCatppuccinOption { name = "polybar"; }; 12 | 13 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 14 | from = [ 15 | "services" 16 | "polybar" 17 | "catppuccin" 18 | ]; 19 | to = "polybar"; 20 | }; 21 | 22 | config = lib.mkIf cfg.enable { 23 | services.polybar = { 24 | extraConfig = lib.fileContents "${sources.polybar}/${cfg.flavor}.ini"; 25 | }; 26 | }; 27 | } 28 | -------------------------------------------------------------------------------- /modules/home-manager/tofi.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.tofi; 8 | in 9 | 10 | { 11 | options.catppuccin.tofi = catppuccinLib.mkCatppuccinOption { name = "tofi"; }; 12 | 13 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 14 | from = [ 15 | "programs" 16 | "tofi" 17 | "catppuccin" 18 | ]; 19 | to = "tofi"; 20 | }; 21 | 22 | config = lib.mkIf cfg.enable { 23 | programs.tofi = { 24 | settings = { 25 | include = sources.tofi + "/catppuccin-${cfg.flavor}"; 26 | }; 27 | }; 28 | }; 29 | } 30 | -------------------------------------------------------------------------------- /modules/nixos/plymouth.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { 3 | config, 4 | lib, 5 | ... 6 | }: 7 | 8 | let 9 | cfg = config.catppuccin.plymouth; 10 | in 11 | 12 | { 13 | options.catppuccin.plymouth = catppuccinLib.mkCatppuccinOption { name = "plymouth"; }; 14 | 15 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 16 | from = [ 17 | "boot" 18 | "plymouth" 19 | "catppuccin" 20 | ]; 21 | to = "plymouth"; 22 | }; 23 | 24 | config = lib.mkIf cfg.enable { 25 | boot.plymouth = { 26 | theme = "catppuccin-${cfg.flavor}"; 27 | themePackages = [ config.catppuccin.sources.plymouth ]; 28 | }; 29 | }; 30 | } 31 | -------------------------------------------------------------------------------- /pkgs/catppuccinInstallHook/script.sh: -------------------------------------------------------------------------------- 1 | # shellcheck shell=bash 2 | # shellcheck disable=SC2154 3 | 4 | catppuccinInstallPhase() { 5 | runHook preInstall 6 | 7 | local targets=() 8 | concatTo targets installTargets=themes 9 | echoCmd 'install targets' "${targets[@]}" 10 | 11 | if [ "${#targets[@]}" -gt 1 ]; then 12 | mkdir -p "$out" 13 | fi 14 | 15 | for target in "${targets[@]}"; do 16 | if [ -e "$target" ]; then 17 | mv "$target" "$out" 18 | fi 19 | done 20 | 21 | runHook postInstall 22 | } 23 | 24 | if [ -z "${dontCatppuccinInstall:-}" ] && [ -z "${installPhase:-}" ]; then 25 | installPhase=catppuccinInstallPhase 26 | fi 27 | -------------------------------------------------------------------------------- /modules/home-manager/foot.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.foot; 8 | in 9 | 10 | { 11 | options.catppuccin.foot = catppuccinLib.mkCatppuccinOption { name = "foot"; }; 12 | 13 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 14 | from = [ 15 | "programs" 16 | "foot" 17 | "catppuccin" 18 | ]; 19 | to = "foot"; 20 | }; 21 | 22 | config = lib.mkIf cfg.enable { 23 | programs.foot = { 24 | settings = { 25 | main.include = sources.foot + "/catppuccin-${cfg.flavor}.ini"; 26 | }; 27 | }; 28 | }; 29 | } 30 | -------------------------------------------------------------------------------- /flake.lock: -------------------------------------------------------------------------------- 1 | { 2 | "nodes": { 3 | "nixpkgs": { 4 | "locked": { 5 | "lastModified": 1763966396, 6 | "narHash": "sha256-6eeL1YPcY1MV3DDStIDIdy/zZCDKgHdkCmsrLJFiZf0=", 7 | "owner": "NixOS", 8 | "repo": "nixpkgs", 9 | "rev": "5ae3b07d8d6527c42f17c876e404993199144b6a", 10 | "type": "github" 11 | }, 12 | "original": { 13 | "owner": "NixOS", 14 | "ref": "nixos-unstable", 15 | "repo": "nixpkgs", 16 | "type": "github" 17 | } 18 | }, 19 | "root": { 20 | "inputs": { 21 | "nixpkgs": "nixpkgs" 22 | } 23 | } 24 | }, 25 | "root": "root", 26 | "version": 7 27 | } 28 | -------------------------------------------------------------------------------- /modules/home-manager/gitui.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.gitui; 8 | in 9 | 10 | { 11 | options.catppuccin.gitui = catppuccinLib.mkCatppuccinOption { name = "gitui"; }; 12 | 13 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 14 | from = [ 15 | "programs" 16 | "gitui" 17 | "catppuccin" 18 | ]; 19 | to = "gitui"; 20 | }; 21 | 22 | config = lib.mkIf cfg.enable { 23 | programs.gitui.theme = builtins.path { 24 | name = "${cfg.flavor}.ron"; 25 | path = "${sources.gitui}/catppuccin-${cfg.flavor}.ron"; 26 | }; 27 | }; 28 | } 29 | -------------------------------------------------------------------------------- /modules/home-manager/halloy.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | cfg = config.catppuccin.halloy; 7 | enable = cfg.enable && config.programs.halloy.enable; 8 | in 9 | 10 | { 11 | options.catppuccin.halloy = catppuccinLib.mkCatppuccinOption { name = "halloy"; }; 12 | 13 | config = lib.mkIf enable { 14 | programs.halloy = { 15 | settings = { 16 | theme = "catppuccin-${cfg.flavor}"; 17 | }; 18 | }; 19 | 20 | xdg.configFile = { 21 | "halloy/themes/catppuccin-${cfg.flavor}.toml".source = 22 | sources.halloy + "/catppuccin-${cfg.flavor}.toml"; 23 | }; 24 | }; 25 | } 26 | -------------------------------------------------------------------------------- /modules/home-manager/zathura.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.zathura; 8 | in 9 | 10 | { 11 | options.catppuccin.zathura = catppuccinLib.mkCatppuccinOption { name = "zathura"; }; 12 | 13 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 14 | from = [ 15 | "programs" 16 | "zathura" 17 | "catppuccin" 18 | ]; 19 | to = "zathura"; 20 | }; 21 | 22 | config = lib.mkIf cfg.enable { 23 | programs.zathura = { 24 | extraConfig = '' 25 | include ${sources.zathura + "/catppuccin-${cfg.flavor}"} 26 | ''; 27 | }; 28 | }; 29 | } 30 | -------------------------------------------------------------------------------- /modules/home-manager/alacritty.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | cfg = config.catppuccin.alacritty; 7 | in 8 | 9 | { 10 | options.catppuccin.alacritty = catppuccinLib.mkCatppuccinOption { name = "alacritty"; }; 11 | 12 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 13 | from = [ 14 | "programs" 15 | "alacritty" 16 | "catppuccin" 17 | ]; 18 | to = "alacritty"; 19 | }; 20 | 21 | config = lib.mkIf cfg.enable { 22 | programs.alacritty = { 23 | settings.general.import = lib.mkBefore [ "${sources.alacritty}/catppuccin-${cfg.flavor}.toml" ]; 24 | }; 25 | }; 26 | } 27 | -------------------------------------------------------------------------------- /pkgs/firefox/package.nix: -------------------------------------------------------------------------------- 1 | { 2 | buildCatppuccinPort, 3 | fetchYarnDeps, 4 | sources, 5 | yarnConfigHook, 6 | yarnBuildHook, 7 | nodejs, 8 | }: 9 | buildCatppuccinPort { 10 | port = "firefox"; 11 | 12 | patches = [ 13 | ./write-themes-to-json.patch 14 | ]; 15 | 16 | yarnOfflineCache = fetchYarnDeps { 17 | yarnLock = sources.firefox + /yarn.lock; 18 | hash = "sha256-EWx1/kujC6HBSJr6d4sTlFwANbZqBQ3FHetHcbMtiVU="; 19 | }; 20 | 21 | yarnBuildScript = "generate"; 22 | 23 | installPhase = '' 24 | mkdir -p $out 25 | cp themes.json $out 26 | ''; 27 | 28 | nativeBuildInputs = [ 29 | yarnConfigHook 30 | yarnBuildHook 31 | nodejs 32 | ]; 33 | } 34 | -------------------------------------------------------------------------------- /modules/home-manager/ghostty.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.ghostty; 8 | themeName = "catppuccin-${cfg.flavor}"; 9 | enable = cfg.enable && config.programs.ghostty.enable; 10 | in 11 | { 12 | options.catppuccin.ghostty = catppuccinLib.mkCatppuccinOption { name = "ghostty"; }; 13 | 14 | config = lib.mkIf enable { 15 | xdg.configFile = { 16 | "ghostty/themes/${themeName}".source = "${sources.ghostty}/${themeName}.conf"; 17 | }; 18 | 19 | programs.ghostty = { 20 | settings = { 21 | theme = "light:${themeName},dark:${themeName}"; 22 | }; 23 | }; 24 | }; 25 | } 26 | -------------------------------------------------------------------------------- /modules/home-manager/atuin.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | cfg = config.catppuccin.atuin; 7 | enable = cfg.enable && config.programs.atuin.enable; 8 | themeName = "catppuccin-${cfg.flavor}-${cfg.accent}"; 9 | in 10 | 11 | { 12 | options.catppuccin.atuin = catppuccinLib.mkCatppuccinOption { 13 | name = "atuin"; 14 | accentSupport = true; 15 | }; 16 | 17 | config = lib.mkIf enable { 18 | programs.atuin = { 19 | settings.theme.name = themeName; 20 | }; 21 | 22 | xdg.configFile = { 23 | "atuin/themes/${themeName}.toml".source = "${sources.atuin}/${cfg.flavor}/${themeName}.toml"; 24 | }; 25 | }; 26 | } 27 | -------------------------------------------------------------------------------- /modules/home-manager/newsboat.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.newsboat; 8 | theme = if cfg.flavor == "latte" then "latte" else "dark"; 9 | in 10 | 11 | { 12 | options.catppuccin.newsboat = catppuccinLib.mkCatppuccinOption { name = "newsboat"; }; 13 | 14 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 15 | from = [ 16 | "programs" 17 | "newsboat" 18 | "catppuccin" 19 | ]; 20 | to = "newsboat"; 21 | }; 22 | 23 | config = lib.mkIf cfg.enable { 24 | programs.newsboat = { 25 | extraConfig = lib.fileContents "${sources.newsboat}/${theme}"; 26 | }; 27 | }; 28 | } 29 | -------------------------------------------------------------------------------- /modules/home-manager/sway.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.sway; 8 | theme = "${sources.sway}/catppuccin-${cfg.flavor}"; 9 | in 10 | 11 | { 12 | options.catppuccin.sway = catppuccinLib.mkCatppuccinOption { name = "sway"; }; 13 | 14 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 15 | from = [ 16 | "wayland" 17 | "windowManager" 18 | "sway" 19 | "catppuccin" 20 | ]; 21 | to = "sway"; 22 | }; 23 | 24 | config = lib.mkIf cfg.enable { 25 | wayland.windowManager.sway = { 26 | extraConfigEarly = '' 27 | include ${theme} 28 | ''; 29 | }; 30 | }; 31 | } 32 | -------------------------------------------------------------------------------- /modules/home-manager/mpv.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.mpv; 8 | in 9 | 10 | { 11 | options.catppuccin.mpv = catppuccinLib.mkCatppuccinOption { 12 | name = "mpv"; 13 | accentSupport = true; 14 | }; 15 | 16 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 17 | from = [ 18 | "programs" 19 | "mpv" 20 | "catppuccin" 21 | ]; 22 | to = "mpv"; 23 | accentSupport = true; 24 | }; 25 | 26 | config = lib.mkIf cfg.enable { 27 | programs.mpv = { 28 | config = { 29 | include = sources.mpv + "/${cfg.flavor}/${cfg.accent}.conf"; 30 | }; 31 | }; 32 | }; 33 | } 34 | -------------------------------------------------------------------------------- /pkgs/whiskers/package.nix: -------------------------------------------------------------------------------- 1 | { 2 | lib, 3 | fetchCatppuccinPort, 4 | nix-update-script, 5 | rustPlatform, 6 | }: 7 | 8 | rustPlatform.buildRustPackage rec { 9 | pname = "whiskers"; 10 | version = "2.5.1"; 11 | 12 | src = fetchCatppuccinPort { 13 | port = "whiskers"; 14 | rev = "refs/tags/v${version}"; 15 | hash = "sha256-OLEXy9MCrPQu1KWICsYhe/ayVqxkYIFwyJoJhgiNDz4="; 16 | }; 17 | 18 | cargoHash = "sha256-CVg7kcOTRa8KfDwiJHQhTPQfK6g3jOMa4h/BCUo3ehw="; 19 | 20 | passthru = { 21 | updateScript = nix-update-script { }; 22 | }; 23 | 24 | meta = { 25 | description = "Soothing port creation tool for the high-spirited!"; 26 | homepage = "https://catppuccin.com"; 27 | license = lib.licenses.mit; 28 | }; 29 | } 30 | -------------------------------------------------------------------------------- /modules/home-manager/element-desktop.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | cfg = config.catppuccin.element-desktop; 7 | in 8 | 9 | { 10 | options.catppuccin.element-desktop = catppuccinLib.mkCatppuccinOption { 11 | name = "element-desktop"; 12 | accentSupport = true; 13 | }; 14 | 15 | config = lib.mkIf cfg.enable { 16 | programs.element-desktop = { 17 | settings = 18 | let 19 | custom-theme = lib.importJSON "${sources.element}/${cfg.flavor}/${cfg.accent}.json"; 20 | in 21 | { 22 | default_theme = custom-theme.name; 23 | setting_defaults.custom_themes = [ custom-theme ]; 24 | }; 25 | }; 26 | }; 27 | } 28 | -------------------------------------------------------------------------------- /pkgs/swaync/package.nix: -------------------------------------------------------------------------------- 1 | { 2 | lib, 3 | fetchurl, 4 | linkFarm, 5 | }: 6 | 7 | let 8 | version = "0.2.3"; 9 | 10 | artifactHashes = { 11 | "frappe.css" = "sha256-9vfro7HpA2T5bk1So8kjUKSXwe5Qnqji7bhs5ASs/Pg="; 12 | "latte.css" = "sha256-Xp7BekqhHUVTiEMMKKeEO9jlL1wtujlFSU0SINNtWZQ="; 13 | "macchiato.css" = "sha256-LMm6nWn1JPPgj5YpppwFG3lXTtXem5atlIvqrDxd0bM="; 14 | "mocha.css" = "sha256-Hie/vDt15nGCy4XWERGy1tUIecROw17GOoasT97kIfc="; 15 | }; 16 | in 17 | 18 | linkFarm "catppuccin-swaync-${version}" ( 19 | lib.mapAttrs ( 20 | artifactName: hash: 21 | 22 | fetchurl { 23 | url = "https://github.com/catppuccin/swaync/releases/download/v${version}/${artifactName}"; 24 | inherit hash; 25 | } 26 | ) artifactHashes 27 | ) 28 | -------------------------------------------------------------------------------- /modules/home-manager/mako.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { 3 | config, 4 | pkgs, 5 | lib, 6 | ... 7 | }: 8 | 9 | let 10 | inherit (config.catppuccin) sources; 11 | 12 | cfg = config.catppuccin.mako; 13 | in 14 | 15 | { 16 | options.catppuccin.mako = catppuccinLib.mkCatppuccinOption { 17 | name = "mako"; 18 | accentSupport = true; 19 | }; 20 | 21 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 22 | from = [ 23 | "services" 24 | "mako" 25 | "catppuccin" 26 | ]; 27 | to = "mako"; 28 | accentSupport = true; 29 | }; 30 | 31 | config.services.mako = lib.mkIf cfg.enable ({ 32 | settings.include = 33 | sources.mako + "/catppuccin-${cfg.flavor}/catppuccin-${cfg.flavor}-${cfg.accent}"; 34 | }); 35 | } 36 | -------------------------------------------------------------------------------- /modules/home-manager/bat.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | cfg = config.catppuccin.bat; 7 | themeName = "Catppuccin ${lib.toSentenceCase cfg.flavor}"; 8 | in 9 | 10 | { 11 | options.catppuccin.bat = catppuccinLib.mkCatppuccinOption { name = "bat"; }; 12 | 13 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 14 | from = [ 15 | "programs" 16 | "bat" 17 | "catppuccin" 18 | ]; 19 | to = "bat"; 20 | }; 21 | 22 | config = lib.mkIf cfg.enable { 23 | programs.bat = { 24 | config.theme = themeName; 25 | 26 | themes.${themeName} = { 27 | src = sources.bat; 28 | file = "${themeName}.tmTheme"; 29 | }; 30 | }; 31 | }; 32 | } 33 | -------------------------------------------------------------------------------- /modules/home-manager/fuzzel.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.fuzzel; 8 | in 9 | 10 | { 11 | options.catppuccin.fuzzel = catppuccinLib.mkCatppuccinOption { 12 | name = "fuzzel"; 13 | accentSupport = true; 14 | }; 15 | 16 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 17 | from = [ 18 | "programs" 19 | "fuzzel" 20 | "catppuccin" 21 | ]; 22 | to = "fuzzel"; 23 | accentSupport = true; 24 | }; 25 | 26 | config = lib.mkIf cfg.enable { 27 | programs.fuzzel = { 28 | settings = { 29 | main.include = sources.fuzzel + "/catppuccin-${cfg.flavor}/${cfg.accent}.ini"; 30 | }; 31 | }; 32 | }; 33 | } 34 | -------------------------------------------------------------------------------- /modules/home-manager/spotify-player.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.spotify-player; 8 | in 9 | 10 | { 11 | options.catppuccin.spotify-player = catppuccinLib.mkCatppuccinOption { 12 | name = "spotify-player"; 13 | }; 14 | 15 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 16 | from = [ 17 | "programs" 18 | "spotify-player" 19 | "catppuccin" 20 | ]; 21 | to = "spotify-player"; 22 | }; 23 | 24 | config = lib.mkIf cfg.enable { 25 | programs.spotify-player = { 26 | settings.theme = "Catppuccin-${cfg.flavor}"; 27 | inherit (lib.importTOML "${sources.spotify-player}/theme.toml") themes; 28 | }; 29 | }; 30 | } 31 | -------------------------------------------------------------------------------- /modules/home-manager/starship.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.starship; 8 | in 9 | 10 | { 11 | options.catppuccin.starship = catppuccinLib.mkCatppuccinOption { name = "starship"; }; 12 | 13 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 14 | from = [ 15 | "programs" 16 | "starship" 17 | "catppuccin" 18 | ]; 19 | to = "starship"; 20 | }; 21 | 22 | config = lib.mkIf cfg.enable { 23 | programs.starship = { 24 | settings = { 25 | format = lib.mkDefault "$all"; 26 | palette = "catppuccin_${cfg.flavor}"; 27 | } 28 | // lib.importTOML "${sources.starship}/${cfg.flavor}.toml"; 29 | }; 30 | }; 31 | } 32 | -------------------------------------------------------------------------------- /modules/home-manager/gh-dash.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.gh-dash; 8 | theme = "${sources.gh-dash}/${cfg.flavor}/catppuccin-${cfg.flavor}-${cfg.accent}.yml"; 9 | in 10 | 11 | { 12 | options.catppuccin.gh-dash = catppuccinLib.mkCatppuccinOption { 13 | name = "gh-dash"; 14 | accentSupport = true; 15 | }; 16 | 17 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 18 | from = [ 19 | "programs" 20 | "gh-dash" 21 | "catppuccin" 22 | ]; 23 | to = "gh-dash"; 24 | accentSupport = true; 25 | }; 26 | 27 | config = lib.mkIf cfg.enable { 28 | programs.gh-dash = { 29 | settings = catppuccinLib.importYAML theme; 30 | }; 31 | }; 32 | } 33 | -------------------------------------------------------------------------------- /modules/home-manager/television.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.television; 8 | enable = config.programs.television.enable && cfg.enable; 9 | in 10 | 11 | { 12 | options.catppuccin.television = catppuccinLib.mkCatppuccinOption { 13 | name = "television"; 14 | accentSupport = true; 15 | }; 16 | 17 | config = lib.mkIf enable { 18 | programs.television = { 19 | settings = { 20 | ui.theme = "catppuccin-${cfg.flavor}-${cfg.accent}"; 21 | }; 22 | }; 23 | 24 | xdg.configFile = { 25 | "television/themes/catppuccin-${cfg.flavor}-${cfg.accent}.toml".source = 26 | sources.television + "/catppuccin-${cfg.flavor}-${cfg.accent}.toml"; 27 | }; 28 | }; 29 | } 30 | -------------------------------------------------------------------------------- /.editorconfig: -------------------------------------------------------------------------------- 1 | # EditorConfig helps developers define and maintain consistent 2 | # coding styles between different editors and IDEs 3 | # EditorConfig is awesome: https://EditorConfig.org 4 | 5 | root = true 6 | 7 | [*] 8 | charset = utf-8 9 | indent_size = 2 10 | indent_style = space 11 | end_of_line = lf 12 | insert_final_newline = true 13 | trim_trailing_whitespace = true 14 | 15 | # go 16 | [*.go] 17 | indent_style = tab 18 | indent_size = 4 19 | 20 | # python 21 | [*.{ini,py,py.tpl,rst}] 22 | indent_size = 4 23 | 24 | # rust 25 | [*.rs] 26 | indent_size = 4 27 | 28 | # documentation, utils 29 | [*.{md,mdx,diff}] 30 | trim_trailing_whitespace = false 31 | 32 | # windows shell scripts 33 | [*.{cmd,bat,ps1}] 34 | end_of_line = crlf 35 | 36 | # npins 37 | [.sources/sources.json] 38 | trim_trailing_whitespace = false 39 | -------------------------------------------------------------------------------- /dev/update-docs-data.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | set -euo pipefail 3 | 4 | root="$(dirname "$0")/.." 5 | 6 | log() { 7 | echo "=> $*" 8 | } 9 | 10 | usage() { 11 | echo "Usage: $0 [flake_ref] [...]" 12 | } 13 | 14 | if [[ $# -lt 1 ]]; then 15 | usage 16 | exit 1 17 | fi 18 | 19 | readonly version_name="$1" 20 | shift 21 | if [[ -n ${1:-} ]]; then 22 | readonly flake_ref="$1" 23 | shift 24 | else 25 | readonly flake_ref="$root/dev" 26 | fi 27 | 28 | for type in "nixos" "home"; do 29 | nix build \ 30 | --no-link --print-out-paths \ 31 | "$flake_ref#${type}OptionsJSON" \ 32 | "$@" | 33 | xargs -I {} cp {}/share/doc/nixos/options.json "$root"/docs/data/"$version_name"-"$type"-options.json 34 | log "generated '$type' options for version '$version_name'" 35 | done 36 | -------------------------------------------------------------------------------- /modules/home-manager/delta.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.delta; 8 | enable = cfg.enable && config.programs.delta.enable; 9 | in 10 | 11 | { 12 | options.catppuccin.delta = catppuccinLib.mkCatppuccinOption { name = "delta"; }; 13 | 14 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 15 | from = [ 16 | "programs" 17 | "git" 18 | "delta" 19 | "catppuccin" 20 | ]; 21 | to = "delta"; 22 | }; 23 | 24 | config = lib.mkIf enable { 25 | programs.delta.options.features = "catppuccin-${cfg.flavor}"; 26 | programs.git = lib.mkIf config.programs.delta.enableGitIntegration { 27 | includes = [ { path = "${sources.delta}/catppuccin.gitconfig"; } ]; 28 | }; 29 | }; 30 | } 31 | -------------------------------------------------------------------------------- /modules/home-manager/fish.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.fish; 8 | enable = cfg.enable && config.programs.fish.enable; 9 | 10 | themeName = "Catppuccin ${lib.toSentenceCase cfg.flavor}"; 11 | in 12 | 13 | { 14 | options.catppuccin.fish = catppuccinLib.mkCatppuccinOption { name = "fish"; }; 15 | 16 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 17 | from = [ 18 | "programs" 19 | "fish" 20 | "catppuccin" 21 | ]; 22 | to = "fish"; 23 | }; 24 | 25 | config = lib.mkIf enable { 26 | xdg.configFile."fish/themes/${themeName}.theme".source = "${sources.fish}/${themeName}.theme"; 27 | 28 | programs.fish.shellInit = '' 29 | fish_config theme choose "${themeName}" 30 | ''; 31 | }; 32 | } 33 | -------------------------------------------------------------------------------- /modules/home-manager/obs.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.obs; 8 | enable = cfg.enable && config.programs.obs-studio.enable; 9 | 10 | themeName = "Catppuccin_${lib.toSentenceCase cfg.flavor}.ovt"; 11 | in 12 | 13 | { 14 | options.catppuccin.obs = catppuccinLib.mkCatppuccinOption { name = "obs-studio"; }; 15 | 16 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 17 | from = [ 18 | "programs" 19 | "obs-studio" 20 | "catppuccin" 21 | ]; 22 | to = "obs"; 23 | }; 24 | 25 | config = lib.mkIf enable { 26 | xdg.configFile = { 27 | "obs-studio/themes/Catppuccin.obt".source = "${sources.obs}/Catppuccin.obt"; 28 | "obs-studio/themes/${themeName}".source = "${sources.obs}/${themeName}"; 29 | }; 30 | }; 31 | } 32 | -------------------------------------------------------------------------------- /modules/home-manager/aerc.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | cfg = config.catppuccin.aerc; 7 | themeName = "catppuccin-${cfg.flavor}"; 8 | in 9 | 10 | { 11 | options.catppuccin.aerc = catppuccinLib.mkCatppuccinOption { name = "aerc"; }; 12 | 13 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 14 | from = [ 15 | "programs" 16 | "aerc" 17 | "catppuccin" 18 | ]; 19 | to = "aerc"; 20 | }; 21 | 22 | config = lib.mkIf cfg.enable { 23 | programs.aerc = { 24 | stylesets.${themeName} = lib.fileContents "${sources.aerc}/${themeName}"; 25 | extraConfig = { 26 | ui = { 27 | styleset-name = themeName; 28 | border-char-vertical = "│"; 29 | border-char-horizontal = "─"; 30 | }; 31 | }; 32 | }; 33 | }; 34 | } 35 | -------------------------------------------------------------------------------- /modules/nixos/grub.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { 3 | config, 4 | lib, 5 | ... 6 | }: 7 | 8 | let 9 | inherit (config.catppuccin) sources; 10 | 11 | cfg = config.catppuccin.grub; 12 | 13 | # TODO @getchoo: upstream this in nixpkgs maybe? idk if they have grub themes 14 | theme = sources.grub + "/share/grub/themes/catppuccin-${cfg.flavor}-grub-theme"; 15 | in 16 | 17 | { 18 | options.catppuccin.grub = catppuccinLib.mkCatppuccinOption { name = "grub"; }; 19 | 20 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 21 | from = [ 22 | "boot" 23 | "loader" 24 | "grub" 25 | "catppuccin" 26 | ]; 27 | to = "grub"; 28 | }; 29 | 30 | config = lib.mkIf cfg.enable { 31 | boot.loader.grub = { 32 | font = "${theme}/font.pf2"; 33 | splashImage = "${theme}/background.png"; 34 | inherit theme; 35 | }; 36 | }; 37 | } 38 | -------------------------------------------------------------------------------- /modules/home-manager/btop.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.btop; 8 | enable = cfg.enable && config.programs.btop.enable; 9 | 10 | themeFile = "catppuccin_${cfg.flavor}.theme"; 11 | theme = sources.btop + "/${themeFile}"; 12 | in 13 | 14 | { 15 | options.catppuccin.btop = catppuccinLib.mkCatppuccinOption { name = "btop"; }; 16 | 17 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 18 | from = [ 19 | "programs" 20 | "btop" 21 | "catppuccin" 22 | ]; 23 | to = "btop"; 24 | }; 25 | 26 | config = lib.mkIf enable { 27 | xdg.configFile = { 28 | "btop/themes/${themeFile}".source = theme; 29 | }; 30 | 31 | programs.btop = { 32 | settings = { 33 | color_theme = themeFile; 34 | }; 35 | }; 36 | }; 37 | } 38 | -------------------------------------------------------------------------------- /modules/home-manager/vesktop.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | cfg = config.catppuccin.vesktop; 6 | themeName = "catppuccin-${cfg.flavor}-${cfg.accent}.theme"; 7 | in 8 | 9 | { 10 | options.catppuccin.vesktop = catppuccinLib.mkCatppuccinOption { 11 | name = "vesktop"; 12 | accentSupport = true; 13 | }; 14 | 15 | config = lib.mkIf cfg.enable { 16 | programs.vesktop.vencord = { 17 | settings.enabledThemes = [ "${themeName}.css" ]; 18 | themes."${themeName}" = '' 19 | /** 20 | * @name Catppuccin ${catppuccinLib.mkFlavorName cfg.flavor} (${lib.toSentenceCase cfg.accent}) 21 | * @author Catppuccin 22 | * @description 🎮 Soothing pastel theme for Discord 23 | * @website https://github.com/catppuccin/discord 24 | **/ 25 | @import url("https://catppuccin.github.io/discord/dist/${themeName}.css"); 26 | ''; 27 | }; 28 | }; 29 | } 30 | -------------------------------------------------------------------------------- /modules/home-manager/yazi.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.yazi; 8 | enable = cfg.enable && config.programs.yazi.enable; 9 | in 10 | 11 | { 12 | options.catppuccin.yazi = catppuccinLib.mkCatppuccinOption { 13 | name = "yazi"; 14 | accentSupport = true; 15 | }; 16 | 17 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 18 | from = [ 19 | "programs" 20 | "yazi" 21 | "catppuccin" 22 | ]; 23 | to = "yazi"; 24 | accentSupport = true; 25 | }; 26 | 27 | config = lib.mkIf enable { 28 | xdg.configFile = { 29 | "yazi/theme.toml".source = 30 | "${sources.yazi}/${cfg.flavor}/catppuccin-${cfg.flavor}-${cfg.accent}.toml"; 31 | 32 | "yazi/Catppuccin-${cfg.flavor}.tmTheme".source = 33 | "${sources.bat}/Catppuccin ${lib.toSentenceCase cfg.flavor}.tmTheme"; 34 | }; 35 | }; 36 | } 37 | -------------------------------------------------------------------------------- /pkgs/cursors/package.nix: -------------------------------------------------------------------------------- 1 | { 2 | lib, 3 | buildCatppuccinPort, 4 | hyprcursor, 5 | inkscape, 6 | just, 7 | python3, 8 | whiskers, 9 | xcur2png, 10 | xorg, 11 | zip, 12 | }: 13 | 14 | buildCatppuccinPort (finalAttrs: { 15 | port = "cursors"; 16 | 17 | postPatch = "patchShebangs scripts/ build"; 18 | 19 | nativeBuildInputs = [ 20 | (python3.withPackages (p: [ p.pyside6 ])) 21 | hyprcursor 22 | inkscape 23 | just 24 | whiskers 25 | xcur2png 26 | xorg.xcursorgen 27 | zip 28 | ]; 29 | 30 | buildPhase = '' 31 | runHook preBuild 32 | 33 | just all 34 | 35 | runHook postBuild 36 | ''; 37 | 38 | installPhase = '' 39 | runHook preInstall 40 | 41 | mkdir -p $out/share 42 | mv dist $out/share/icons 43 | 44 | runHook postInstall 45 | ''; 46 | 47 | meta = { 48 | description = "Catppuccin cursor theme based on Volantes"; 49 | license = lib.licenses.gpl2; 50 | platforms = lib.platforms.linux; 51 | }; 52 | }) 53 | -------------------------------------------------------------------------------- /modules/nixos/fcitx5.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { 3 | config, 4 | lib, 5 | ... 6 | }: 7 | 8 | let 9 | inherit (config.catppuccin) sources; 10 | cfg = config.catppuccin.fcitx5; 11 | in 12 | 13 | { 14 | options.catppuccin.fcitx5 = 15 | catppuccinLib.mkCatppuccinOption { 16 | name = "Fcitx5"; 17 | accentSupport = true; 18 | } 19 | // { 20 | enableRounded = lib.mkEnableOption "rounded corners for the Fcitx5 theme"; 21 | }; 22 | 23 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 24 | from = [ 25 | "i18n" 26 | "inputMethod" 27 | "fcitx5" 28 | "catppuccin" 29 | ]; 30 | to = "fcitx5"; 31 | accentSupport = true; 32 | }; 33 | 34 | config = lib.mkIf cfg.enable { 35 | i18n.inputMethod.fcitx5 = { 36 | addons = [ 37 | (sources.fcitx5.override { inherit (cfg) enableRounded; }) 38 | ]; 39 | settings.addons.classicui.globalSection.Theme = "catppuccin-${cfg.flavor}-${cfg.accent}"; 40 | }; 41 | }; 42 | } 43 | -------------------------------------------------------------------------------- /modules/home-manager/chrome.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | let 4 | cfg = config.catppuccin; 5 | 6 | identifiers = { 7 | frappe = "olhelnoplefjdmncknfphenjclimckaf"; 8 | latte = "jhjnalhegpceacdhbplhnakmkdliaddd"; 9 | macchiato = "cmpdlhmnmjhihmcfnigoememnffkimlk"; 10 | mocha = "bkkmolkhemgaeaeggcmfbghljjjoofoh"; 11 | }; 12 | 13 | # Google Chrome is not supported since it does not support extensions 14 | # See nix-community/home-manager#1383 for more information. 15 | supportedBrowsers = [ 16 | "brave" 17 | "chromium" 18 | "vivaldi" 19 | ]; 20 | 21 | generateConfig = 22 | browser: 23 | lib.mkIf cfg.${browser}.enable { 24 | programs.${browser}.extensions = [ { id = identifiers.${cfg.${browser}.flavor}; } ]; 25 | }; 26 | in 27 | { 28 | options.catppuccin = lib.genAttrs supportedBrowsers ( 29 | name: catppuccinLib.mkCatppuccinOption { inherit name; } 30 | ); 31 | 32 | config = lib.mkMerge (map generateConfig supportedBrowsers); 33 | } 34 | -------------------------------------------------------------------------------- /modules/home-manager/micro.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.micro; 8 | enable = cfg.enable && config.programs.micro.enable; 9 | 10 | themePath = 11 | "catppuccin-${cfg.flavor}" + lib.optionalString cfg.transparent "-transparent" + ".micro"; 12 | in 13 | 14 | { 15 | options.catppuccin.micro = catppuccinLib.mkCatppuccinOption { name = "micro"; } // { 16 | transparent = lib.mkEnableOption "transparent version of flavor"; 17 | }; 18 | 19 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 20 | from = [ 21 | "programs" 22 | "micro" 23 | "catppuccin" 24 | ]; 25 | to = "micro"; 26 | }; 27 | 28 | config = lib.mkIf enable { 29 | programs.micro = { 30 | settings = { 31 | colorscheme = lib.removeSuffix ".micro" themePath; 32 | }; 33 | }; 34 | 35 | xdg.configFile = { 36 | "micro/colorschemes/${themePath}".source = "${sources.micro}/${themePath}"; 37 | }; 38 | }; 39 | } 40 | -------------------------------------------------------------------------------- /modules/home-manager/rofi.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.rofi; 8 | enable = config.programs.rofi.enable && cfg.enable; 9 | in 10 | 11 | { 12 | options.catppuccin.rofi = catppuccinLib.mkCatppuccinOption { name = "rofi"; }; 13 | 14 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 15 | from = [ 16 | "programs" 17 | "rofi" 18 | "catppuccin" 19 | ]; 20 | to = "rofi"; 21 | }; 22 | 23 | config = lib.mkIf enable { 24 | programs.rofi = { 25 | theme = { 26 | "@theme" = "catppuccin-default"; 27 | "@import" = "catppuccin-${cfg.flavor}"; 28 | }; 29 | }; 30 | 31 | xdg.dataFile = { 32 | "rofi/themes/catppuccin-default.rasi" = { 33 | source = sources.rofi + "/catppuccin-default.rasi"; 34 | }; 35 | "rofi/themes/catppuccin-${cfg.flavor}.rasi" = { 36 | source = sources.rofi + "/themes/catppuccin-${cfg.flavor}.rasi"; 37 | }; 38 | }; 39 | }; 40 | } 41 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "catppuccin-nix-website", 3 | "version": "0.0.1", 4 | "private": true, 5 | "type": "module", 6 | "scripts": { 7 | "astro": "astro", 8 | "build": "astro check && astro build", 9 | "check": "astro check", 10 | "dev": "astro dev", 11 | "preview": "astro preview", 12 | "fmt": "prettier --write ." 13 | }, 14 | "devDependencies": { 15 | "@astrojs/check": "^0.9.4", 16 | "@astrojs/starlight": "^0.36.0", 17 | "@catppuccin/starlight": "^1.0.2", 18 | "astro": "^5.13.3", 19 | "prettier": "^3.6.2", 20 | "prettier-plugin-astro": "^0.14.1", 21 | "sharp": "^0.34.3", 22 | "typescript": "^5.9.2" 23 | }, 24 | "prettier": { 25 | "plugins": [ 26 | "prettier-plugin-astro" 27 | ] 28 | }, 29 | "packageManager": "pnpm@10.17.1+sha512.17c560fca4867ae9473a3899ad84a88334914f379be46d455cbf92e5cf4b39d34985d452d2583baf19967fa76cb5c17bc9e245529d0b98745721aa7200ecaf7a", 30 | "pnpm": { 31 | "onlyBuiltDependencies": [ 32 | "esbuild", 33 | "sharp" 34 | ] 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /modules/home-manager/anki.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { 3 | config, 4 | pkgs, 5 | lib, 6 | ... 7 | }: 8 | 9 | let 10 | cfg = config.catppuccin.anki; 11 | in 12 | 13 | { 14 | options.catppuccin.anki = catppuccinLib.mkCatppuccinOption { name = "anki"; }; 15 | 16 | config = lib.mkIf cfg.enable { 17 | programs.anki = { 18 | addons = with pkgs.ankiAddons; [ 19 | (recolor.withConfig { 20 | config = 21 | let 22 | polarity = if config.catppuccin.flavor == "latte" then "light" else "dark"; 23 | flavor = lib.toSentenceCase config.catppuccin.flavor; 24 | version = builtins.splitVersion recolor.version; 25 | in 26 | (lib.importJSON "${recolor}/share/anki/addons/recolor/themes/(${polarity}) Catppuccin ${flavor}.json") 27 | // { 28 | version = { 29 | major = lib.toInt (builtins.elemAt version 0); 30 | minor = lib.toInt (builtins.elemAt version 1); 31 | }; 32 | }; 33 | }) 34 | ]; 35 | }; 36 | }; 37 | } 38 | -------------------------------------------------------------------------------- /modules/home-manager/swaync.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { 3 | config, 4 | lib, 5 | pkgs, 6 | ... 7 | }: 8 | 9 | let 10 | inherit (config.catppuccin) sources; 11 | cfg = config.catppuccin.swaync; 12 | 13 | enable = cfg.enable && config.services.swaync.enable; 14 | 15 | theme = pkgs.substitute { 16 | src = sources.swaync + "/${cfg.flavor}.css"; 17 | 18 | substitutions = [ 19 | "--replace-warn" 20 | "Ubuntu Nerd Font" 21 | cfg.font 22 | ]; 23 | }; 24 | in 25 | 26 | { 27 | options.catppuccin.swaync = 28 | catppuccinLib.mkCatppuccinOption { 29 | name = "swaync"; 30 | } 31 | // { 32 | font = lib.mkOption { 33 | type = lib.types.str; 34 | default = "Ubuntu Nerd Font"; 35 | description = "Font to use for the notification center"; 36 | }; 37 | }; 38 | 39 | config = lib.mkIf enable { 40 | services.swaync.style = theme; 41 | 42 | # Install the default font if it is selected 43 | home.packages = lib.mkIf (cfg.font == "Ubuntu Nerd Font") [ 44 | pkgs.nerd-fonts.ubuntu 45 | ]; 46 | }; 47 | } 48 | -------------------------------------------------------------------------------- /modules/home-manager/qutebrowser.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { 3 | config, 4 | lib, 5 | pkgs, 6 | ... 7 | }: 8 | 9 | let 10 | inherit (config.catppuccin) sources; 11 | cfg = config.catppuccin.qutebrowser; 12 | enable = cfg.enable && config.programs.qutebrowser.enable; 13 | 14 | files = { 15 | "qutebrowser/catppuccin".source = sources.qutebrowser; 16 | }; 17 | in 18 | 19 | { 20 | options.catppuccin.qutebrowser = catppuccinLib.mkCatppuccinOption { name = "qutebrowser"; } // { 21 | plainLook = lib.mkEnableOption "plain look for the menu rows"; 22 | }; 23 | 24 | config = lib.mkIf enable { 25 | programs.qutebrowser = { 26 | extraConfig = lib.mkMerge [ 27 | (lib.mkBefore "import catppuccin") 28 | (lib.mkAfter "catppuccin.setup(c, '${cfg.flavor}', ${lib.toSentenceCase (lib.boolToString cfg.plainLook)})") 29 | ]; 30 | }; 31 | 32 | home.file = lib.mkIf pkgs.stdenv.hostPlatform.isDarwin ( 33 | lib.mapAttrs' (name: lib.nameValuePair ("." + name)) files 34 | ); 35 | 36 | xdg.configFile = lib.mkIf pkgs.stdenv.hostPlatform.isLinux files; 37 | }; 38 | } 39 | -------------------------------------------------------------------------------- /modules/nixos/tty.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.tty; 8 | enable = cfg.enable && config.console.enable; 9 | palette = (lib.importJSON "${sources.palette}/palette.json").${cfg.flavor}.colors; 10 | in 11 | 12 | { 13 | options.catppuccin.tty = catppuccinLib.mkCatppuccinOption { name = "tty"; }; 14 | 15 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 16 | from = [ 17 | "console" 18 | "catppuccin" 19 | ]; 20 | to = "tty"; 21 | }; 22 | 23 | config = lib.mkIf enable { 24 | # Manually populate with colors from catppuccin/tty 25 | # Make sure to strip initial # from hex codes 26 | console.colors = map (color: (lib.substring 1 6 palette.${color}.hex)) [ 27 | "base" 28 | "red" 29 | "green" 30 | "yellow" 31 | "blue" 32 | "pink" 33 | "teal" 34 | "subtext1" 35 | 36 | "surface2" 37 | "red" 38 | "green" 39 | "yellow" 40 | "blue" 41 | "pink" 42 | "teal" 43 | "subtext0" 44 | ]; 45 | }; 46 | } 47 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2023 Catppuccin 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /modules/home-manager/skim.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.skim; 8 | palette = (lib.importJSON "${sources.palette}/palette.json").${cfg.flavor}.colors; 9 | in 10 | 11 | { 12 | options.catppuccin.skim = catppuccinLib.mkCatppuccinOption { name = "skim"; }; 13 | 14 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 15 | from = [ 16 | "programs" 17 | "skim" 18 | "catppuccin" 19 | ]; 20 | to = "skim"; 21 | }; 22 | 23 | config = lib.mkIf cfg.enable { 24 | programs.skim = { 25 | defaultOptions = [ 26 | "--color=fg:${palette.text.hex},bg:${palette.base.hex},matched:${palette.surface0.hex},matched_bg:${palette.flamingo.hex},current:${palette.text.hex},current_bg:${palette.surface1.hex},current_match:${palette.base.hex},current_match_bg:${palette.rosewater.hex},spinner:${palette.green.hex},info:${palette.mauve.hex},prompt:${palette.blue.hex},cursor:${palette.red.hex},selected:${palette.maroon.hex},header:${palette.teal.hex},border:${palette.overlay0.hex}" 27 | ]; 28 | }; 29 | }; 30 | } 31 | -------------------------------------------------------------------------------- /modules/home-manager/cava.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.cava; 8 | flavor = "${cfg.flavor}" + lib.optionalString cfg.transparent "-transparent"; 9 | enable = cfg.enable && config.programs.cava.enable; 10 | in 11 | 12 | { 13 | options.catppuccin.cava = catppuccinLib.mkCatppuccinOption { name = "cava"; } // { 14 | transparent = lib.mkEnableOption "transparent version of flavor"; 15 | }; 16 | 17 | imports = 18 | (catppuccinLib.mkRenamedCatppuccinOptions { 19 | from = [ 20 | "programs" 21 | "cava" 22 | "catppuccin" 23 | ]; 24 | to = "cava"; 25 | }) 26 | ++ [ 27 | (lib.mkRenamedOptionModule 28 | [ 29 | "programs" 30 | "cava" 31 | "catppuccin" 32 | "transparent" 33 | ] 34 | [ 35 | "catppuccin" 36 | "cava" 37 | "transparent" 38 | ] 39 | ) 40 | ]; 41 | 42 | config = lib.mkIf enable { 43 | xdg.configFile."cava/themes/catppuccin".source = sources.cava + "/${flavor}.cava"; 44 | programs.cava.settings.color.theme = "catppuccin"; 45 | }; 46 | } 47 | -------------------------------------------------------------------------------- /docs/data/options.ts: -------------------------------------------------------------------------------- 1 | import { readFileSync } from "node:fs"; 2 | 3 | const branches = ["main", "25.05", "v1.1", "v1.2"]; 4 | 5 | const groupOptionsByModule = (options: Object) => { 6 | return Object.groupBy(Object.entries(options), ([optionName, _]) => { 7 | const optionNameParts = optionName.split("."); 8 | // Make the (somewhat naive) assumption that modules are either at the root namespace, or one level below 9 | // ex: `catppuccin.foo.enable` and `catppuccin.foo.bar.enable` => `catppuccin.foo` 10 | // ex: `catppuccin.enable` => `catppuccin` 11 | const cutoff = Math.min(2, optionNameParts.length - 1); 12 | return optionNameParts.splice(0, cutoff).join("."); 13 | }); 14 | }; 15 | 16 | const loadOptionsFromJSON = (version: string, type: string): Object => { 17 | const data = JSON.parse( 18 | readFileSync(`./docs/data/${version}-${type}-options.json`, "utf-8"), 19 | ); 20 | const options = groupOptionsByModule(data); 21 | return options; 22 | }; 23 | 24 | export const optionsData = Object.fromEntries( 25 | branches.map((version) => [ 26 | version, 27 | { 28 | nixos: loadOptionsFromJSON(version, "nixos"), 29 | home: loadOptionsFromJSON(version, "home"), 30 | }, 31 | ]), 32 | ); 33 | -------------------------------------------------------------------------------- /modules/home-manager/wezterm.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | let 4 | inherit (config.catppuccin) sources; 5 | cfg = config.catppuccin.wezterm; 6 | in 7 | { 8 | options.catppuccin.wezterm = 9 | catppuccinLib.mkCatppuccinOption { 10 | name = "wezterm"; 11 | accentSupport = true; 12 | } 13 | // { 14 | apply = lib.mkOption { 15 | type = lib.types.bool; 16 | default = false; 17 | description = "Apply Catppuccin theme to WezTerm."; 18 | }; 19 | }; 20 | 21 | config = lib.mkIf cfg.enable { 22 | programs.wezterm = { 23 | extraConfig = lib.mkBefore ( 24 | '' 25 | local catppuccin_plugin = "${sources.wezterm}/plugin/init.lua" 26 | local catppuccin_config = { 27 | flavor = "${cfg.flavor}", 28 | accent = "${cfg.accent}", 29 | } 30 | '' 31 | + lib.optionalString cfg.apply '' 32 | local config = {} 33 | if wezterm.config_builder then 34 | config = wezterm.config_builder() 35 | end 36 | 37 | dofile("${sources.wezterm}/plugin/init.lua").apply_to_config(config, catppuccin_config) 38 | '' 39 | ); 40 | }; 41 | }; 42 | } 43 | -------------------------------------------------------------------------------- /.github/workflows/backport.yml: -------------------------------------------------------------------------------- 1 | # Based on https://github.com/NixOS/nixpkgs/blob/c81ecdf95b3a0f73ded448f14416cd66beeb5e1a/.github/workflows/backport.yml 2 | name: Backport 3 | 4 | on: 5 | pull_request_target: 6 | types: [closed, labeled] 7 | 8 | # WARNING: 9 | # When extending this action, be aware that $GITHUB_TOKEN allows write access to 10 | # the GitHub repository. This means that it should not evaluate user input in a 11 | # way that allows code injection. 12 | 13 | jobs: 14 | backport: 15 | name: Backport Pull Request 16 | 17 | if: ${{ github.repository_owner == 'catppuccin' && github.event.pull_request.merged == true && (github.event_name != 'labeled' || startsWith('backport', github.event.label.name)) }} 18 | 19 | runs-on: ubuntu-latest 20 | 21 | permissions: 22 | contents: write 23 | pull-requests: write 24 | 25 | steps: 26 | - name: Checkout repository 27 | uses: actions/checkout@v6 28 | with: 29 | ref: ${{ github.event.pull_request.head.sha }} 30 | 31 | - name: Create backport PRs 32 | uses: korthout/backport-action@v3 33 | with: 34 | pull_description: |- 35 | Bot-based backport to `${target_branch}`, triggered by a label in #${pull_number}. 36 | -------------------------------------------------------------------------------- /pkgs/catwalk/package.nix: -------------------------------------------------------------------------------- 1 | { 2 | lib, 3 | stdenv, 4 | buildPackages, 5 | fetchCatppuccinPort, 6 | installShellFiles, 7 | nix-update-script, 8 | rustPlatform, 9 | }: 10 | 11 | rustPlatform.buildRustPackage rec { 12 | pname = "catwalk"; 13 | version = "1.3.2"; 14 | 15 | src = fetchCatppuccinPort { 16 | port = "catwalk"; 17 | rev = "refs/tags/v${version}"; 18 | hash = "sha256-Yj9xTQJ0eu3Ymi2R9fgYwBJO0V+4bN4MOxXCJGQ8NjU="; 19 | }; 20 | 21 | cargoHash = "sha256-stO8ejSC4UeEeMZZLIJ8Wabn7A6ZrWQlU5cZDSm2AVc="; 22 | 23 | nativeBuildInputs = [ installShellFiles ]; 24 | 25 | postInstall = 26 | let 27 | catwalk = stdenv.hostPlatform.emulator buildPackages + " $out/bin/catwalk"; 28 | in 29 | lib.optionalString (stdenv.hostPlatform.emulatorAvailable buildPackages) '' 30 | installShellCompletion --cmd catwalk \ 31 | --bash <(${catwalk} completion bash) \ 32 | --fish <(${catwalk} completion fish) \ 33 | --zsh <(${catwalk} completion zsh) 34 | ''; 35 | 36 | passthru = { 37 | updateScript = nix-update-script { }; 38 | }; 39 | 40 | meta = { 41 | description = "Soothing pastel previews for the high-spirited!"; 42 | homepage = "https://catppuccin.com"; 43 | license = lib.licenses.mit; 44 | }; 45 | } 46 | -------------------------------------------------------------------------------- /modules/home-manager/fzf.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.fzf; 8 | palette = (lib.importJSON "${sources.palette}/palette.json").${cfg.flavor}.colors; 9 | 10 | # Manually populate with colors from catppuccin/fzf 11 | # The ordering is meant to match the order of catppuccin/fzf to make comparison easier 12 | colors = lib.attrsets.mapAttrs (_: color: palette.${color}.hex) { 13 | "bg+" = "surface0"; 14 | bg = "base"; 15 | spinner = "rosewater"; 16 | hl = cfg.accent; 17 | fg = "text"; 18 | header = cfg.accent; 19 | info = cfg.accent; 20 | pointer = cfg.accent; 21 | marker = cfg.accent; 22 | "fg+" = "text"; 23 | prompt = cfg.accent; 24 | "hl+" = cfg.accent; 25 | }; 26 | in 27 | 28 | { 29 | options.catppuccin.fzf = catppuccinLib.mkCatppuccinOption { 30 | name = "fzf"; 31 | accentSupport = true; 32 | }; 33 | 34 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 35 | from = [ 36 | "programs" 37 | "fzf" 38 | "catppuccin" 39 | ]; 40 | to = "fzf"; 41 | accentSupport = true; 42 | }; 43 | 44 | config = lib.mkIf cfg.enable { 45 | programs.fzf = { 46 | inherit colors; 47 | }; 48 | }; 49 | } 50 | -------------------------------------------------------------------------------- /pkgs/buildCatppuccinPort/package.nix: -------------------------------------------------------------------------------- 1 | { 2 | lib, 3 | stdenvNoCC, 4 | catppuccinInstallHook, 5 | fetchCatppuccinPort, 6 | sources, 7 | }: 8 | 9 | lib.extendMkDerivation { 10 | constructDrv = stdenvNoCC.mkDerivation; 11 | 12 | extendDrvArgs = 13 | finalAttrs: args: 14 | args 15 | // { 16 | pname = args.pname or "catppuccin-${finalAttrs.port}"; 17 | version = 18 | args.version 19 | or ("0" + lib.optionalString (finalAttrs ? "lastModified") "-unstable-${finalAttrs.lastModified}"); 20 | 21 | src = 22 | args.src or sources.${finalAttrs.port} or (fetchCatppuccinPort { 23 | inherit (finalAttrs) port; 24 | inherit (finalAttrs) rev hash; 25 | fetchSubmodules = finalAttrs.fetchSubmodules or false; 26 | }); 27 | 28 | nativeBuildInputs = args.nativeBuildInputs or [ ] ++ [ catppuccinInstallHook ]; 29 | 30 | meta = { 31 | description = "Soothing pastel theme for ${finalAttrs.port}"; 32 | homepage = "https://github.com/catppuccin/${finalAttrs.port}"; 33 | license = lib.licenses.mit; 34 | maintainers = with lib.maintainers; [ 35 | getchoo 36 | isabelroses 37 | ]; 38 | platforms = lib.platforms.all; 39 | } 40 | // args.meta or { }; 41 | }; 42 | } 43 | -------------------------------------------------------------------------------- /modules/nixos/gtk.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { 3 | config, 4 | lib, 5 | pkgs, 6 | ... 7 | }: 8 | 9 | let 10 | cfg = config.catppuccin.gtk; 11 | in 12 | { 13 | options.catppuccin.gtk = { 14 | icon = catppuccinLib.mkCatppuccinOption { 15 | name = "GTK modified Papirus icon theme"; 16 | 17 | accentSupport = true; 18 | }; 19 | }; 20 | 21 | config = 22 | lib.mkIf 23 | ( 24 | cfg.icon.enable 25 | && (config.services.desktopManager.gnome.enable || config.services.displayManager.gdm.enable) 26 | ) 27 | { 28 | services.displayManager.environment.XDG_DATA_DIRS = ( 29 | (lib.makeSearchPath "share" [ 30 | (pkgs.catppuccin-papirus-folders.override { inherit (cfg.icon) accent flavor; }) 31 | ]) 32 | + ":" 33 | ); 34 | 35 | programs.dconf.profiles.gdm.databases = [ 36 | { 37 | lockAll = true; 38 | settings."org/gnome/desktop/interface" = 39 | let 40 | # use the light icon theme for latte 41 | polarity = if cfg.icon.flavor == "latte" then "Light" else "Dark"; 42 | in 43 | { 44 | icon-theme = "Papirus-${polarity}"; 45 | }; 46 | } 47 | ]; 48 | }; 49 | } 50 | -------------------------------------------------------------------------------- /modules/home-manager/hyprlock.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { 3 | config, 4 | lib, 5 | pkgs, 6 | ... 7 | }: 8 | 9 | let 10 | inherit (config.catppuccin) sources; 11 | 12 | cfg = config.catppuccin.hyprlock; 13 | in 14 | 15 | { 16 | options.catppuccin.hyprlock = 17 | catppuccinLib.mkCatppuccinOption { 18 | name = "hyprlock"; 19 | accentSupport = true; 20 | } 21 | // { 22 | useDefaultConfig = lib.mkEnableOption "the default configuration of the port" // { 23 | default = true; 24 | }; 25 | }; 26 | 27 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 28 | from = [ 29 | "programs" 30 | "hyprlock" 31 | "catppuccin" 32 | ]; 33 | to = "hyprlock"; 34 | accentSupport = true; 35 | }; 36 | 37 | config = lib.mkIf cfg.enable { 38 | programs.hyprlock = { 39 | settings = { 40 | source = [ 41 | "${sources.hyprland}/${cfg.flavor}.conf" 42 | 43 | # Define accents in file to ensure they appear before user vars 44 | (pkgs.writeText "hyprland-${cfg.accent}-accent.conf" '' 45 | $accent = ''$${cfg.accent} 46 | $accentAlpha = ''$${cfg.accent}Alpha 47 | '') 48 | ] 49 | ++ lib.optional cfg.useDefaultConfig sources.hyprlock; 50 | }; 51 | }; 52 | }; 53 | } 54 | -------------------------------------------------------------------------------- /modules/home-manager/cursors.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { 3 | config, 4 | lib, 5 | ... 6 | }: 7 | 8 | let 9 | inherit (config.catppuccin) sources; 10 | 11 | cfg = config.catppuccin.cursors; 12 | 13 | # "dark" and "light" can be used alongside the regular accents 14 | cursorAccentType = lib.types.mergeTypes catppuccinLib.types.accent ( 15 | lib.types.enum [ 16 | "dark" 17 | "light" 18 | ] 19 | ); 20 | in 21 | 22 | { 23 | options.catppuccin.cursors = 24 | catppuccinLib.mkCatppuccinOption { 25 | name = "pointer cursors"; 26 | # NOTE: We exclude this as there is no `enable` option in the upstream 27 | # module to guard it 28 | useGlobalEnable = false; 29 | } 30 | // { 31 | accent = lib.mkOption { 32 | type = cursorAccentType; 33 | default = config.catppuccin.accent; 34 | description = "Catppuccin accent for pointer cursors"; 35 | }; 36 | }; 37 | 38 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 39 | from = [ 40 | "catppuccin" 41 | "pointerCursor" 42 | ]; 43 | to = "cursors"; 44 | accentSupport = true; 45 | }; 46 | 47 | config = lib.mkIf cfg.enable { 48 | home.pointerCursor = { 49 | name = "catppuccin-${cfg.flavor}-${cfg.accent}-cursors"; 50 | package = sources.cursors; 51 | }; 52 | }; 53 | } 54 | -------------------------------------------------------------------------------- /.github/workflows/format.yml: -------------------------------------------------------------------------------- 1 | name: Format 2 | 3 | on: 4 | push: 5 | branches: 6 | - "main" 7 | - "release-*" 8 | workflow_dispatch: 9 | 10 | jobs: 11 | nix: 12 | name: Nix files 13 | 14 | runs-on: ubuntu-latest 15 | 16 | steps: 17 | - name: Checkout repository 18 | uses: actions/checkout@v6 19 | with: 20 | token: ${{ secrets.PUSH_TOKEN }} 21 | 22 | - name: Set Git user info 23 | run: | 24 | git config user.name 'github-actions[bot]' 25 | git config user.email 'github-actions[bot]@users.noreply.github.com' 26 | 27 | - name: Get short revision 28 | id: rev 29 | run: echo "rev=$(git rev-parse --short HEAD)" >> "$GITHUB_OUTPUT" 30 | 31 | - name: Install Nix 32 | uses: cachix/install-nix-action@v31 33 | 34 | - name: Format Nix files 35 | run: | 36 | nix fmt 37 | 38 | - name: Install Node modules 39 | run: | 40 | nix develop --command pnpm install 41 | 42 | - name: Format with Prettier 43 | run: | 44 | nix develop --command nrr fmt 45 | 46 | - name: Commit changes 47 | run: | 48 | if ! git diff --color=always --exit-code; then 49 | git commit -am "style: format ${{ steps.rev.outputs.rev }}" 50 | git push 51 | fi 52 | -------------------------------------------------------------------------------- /modules/home-manager/hyprland.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { 3 | config, 4 | lib, 5 | pkgs, 6 | ... 7 | }: 8 | 9 | let 10 | inherit (config.catppuccin) sources cursors; 11 | cfg = config.catppuccin.hyprland; 12 | enable = cfg.enable && config.wayland.windowManager.hyprland.enable; 13 | in 14 | 15 | { 16 | options.catppuccin.hyprland = catppuccinLib.mkCatppuccinOption { 17 | name = "hyprland"; 18 | accentSupport = true; 19 | }; 20 | 21 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 22 | from = [ 23 | "wayland" 24 | "windowManager" 25 | "hyprland" 26 | "catppuccin" 27 | ]; 28 | to = "hyprland"; 29 | accentSupport = true; 30 | }; 31 | 32 | config = lib.mkIf enable { 33 | home.sessionVariables = lib.mkIf cursors.enable { 34 | HYPRCURSOR_SIZE = config.home.pointerCursor.size; 35 | HYPRCURSOR_THEME = "catppuccin-${cursors.flavor}-${cursors.accent}-cursors"; 36 | }; 37 | 38 | wayland.windowManager.hyprland = { 39 | settings = { 40 | source = [ 41 | "${sources.hyprland}/${cfg.flavor}.conf" 42 | 43 | # Define accents in file to ensure they appear before user vars 44 | (pkgs.writeText "hyprland-${cfg.accent}-accent.conf" '' 45 | $accent = ''$${cfg.accent} 46 | $accentAlpha = ''$${cfg.accent}Alpha 47 | '') 48 | ]; 49 | }; 50 | }; 51 | }; 52 | } 53 | -------------------------------------------------------------------------------- /modules/home-manager/helix.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.helix; 8 | enable = cfg.enable && config.programs.helix.enable; 9 | subdir = if cfg.useItalics then "default" else "no_italics"; 10 | in 11 | 12 | { 13 | options.catppuccin.helix = catppuccinLib.mkCatppuccinOption { name = "helix"; } // { 14 | useItalics = lib.mkEnableOption "Italics in Catppuccin theme for Helix"; 15 | }; 16 | 17 | imports = 18 | (catppuccinLib.mkRenamedCatppuccinOptions { 19 | from = [ 20 | "programs" 21 | "helix" 22 | "catppuccin" 23 | ]; 24 | to = "helix"; 25 | }) 26 | ++ [ 27 | (lib.mkRenamedOptionModule 28 | [ 29 | "programs" 30 | "helix" 31 | "catppuccin" 32 | "useItalics" 33 | ] 34 | [ 35 | "catppuccin" 36 | "helix" 37 | "useItalics" 38 | ] 39 | ) 40 | ]; 41 | 42 | config = lib.mkIf enable { 43 | programs.helix = { 44 | settings = { 45 | theme = "catppuccin-${cfg.flavor}"; 46 | editor.color-modes = lib.mkDefault true; 47 | }; 48 | }; 49 | 50 | xdg.configFile = { 51 | "helix/themes/catppuccin-${cfg.flavor}.toml".source = 52 | "${sources.helix}/${subdir}/catppuccin_${cfg.flavor}.toml"; 53 | }; 54 | }; 55 | } 56 | -------------------------------------------------------------------------------- /pkgs/firefox/write-themes-to-json.patch: -------------------------------------------------------------------------------- 1 | diff --git a/main.js b/main.js 2 | index a4b6e93..42c1824 100644 3 | --- a/main.js 4 | +++ b/main.js 5 | @@ -1,5 +1,6 @@ 6 | import JsonUrl from "json-url"; 7 | import { variants } from "@catppuccin/palette"; 8 | +import { writeFileSync } from "node:fs"; 9 | 10 | const accents = [ 11 | "rosewater", 12 | @@ -37,6 +38,8 @@ const capitalize = (s) => { 13 | }; 14 | 15 | (async () => { 16 | + let themes = {}; 17 | + 18 | for (const flavour of Object.keys(variants)) { 19 | console.log(`
\n${capitalize(flavour)}\n`); 20 | const lib = {}; 21 | @@ -51,6 +54,8 @@ const capitalize = (s) => { 22 | }; 23 | }); 24 | 25 | + themes[flavour] = {}; 26 | + 27 | for (const accent of accents) { 28 | lib.accent = lib[accent]; 29 | 30 | @@ -99,6 +104,8 @@ const capitalize = (s) => { 31 | title: `Catppuccin ${flavour} ${accent}`, 32 | }; 33 | 34 | + themes[flavour][accent] = theme; 35 | + 36 | const url = await jsonCodec.compress(theme); 37 | const link = `${capitalize( 38 | accent 39 | @@ -108,4 +115,6 @@ const capitalize = (s) => { 40 | } 41 | console.log(`
`); 42 | } 43 | + 44 | + writeFileSync("themes.json", JSON.stringify(themes)); 45 | })(); 46 | -------------------------------------------------------------------------------- /modules/home-manager/xfce4-terminal.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | cfg = config.catppuccin.xfce4-terminal; 7 | enable = cfg.enable; 8 | themeName = "catppuccin-${cfg.flavor}"; 9 | 10 | toCaseWithSeparator = 11 | separator: string: 12 | let 13 | words = lib.splitStringBy ( 14 | prev: curr: prev != "" && builtins.match "[A-Z]" curr != null 15 | ) true string; 16 | converted = lib.concatMapStringsSep separator lib.toLower words; 17 | in 18 | converted; 19 | 20 | toKebabCase = toCaseWithSeparator "-"; 21 | 22 | normalizeValue = 23 | value: 24 | if value == "TRUE" then 25 | true 26 | else if value == "FALSE" then 27 | false 28 | else 29 | value; 30 | 31 | themeFile = sources.xfce4-terminal + "/${themeName}.theme"; 32 | 33 | themeProperties = builtins.removeAttrs (catppuccinLib.importINI themeFile).Scheme [ "Name" ]; 34 | 35 | terminalSettings = lib.listToAttrs ( 36 | lib.mapAttrsToList (name: value: { 37 | name = toKebabCase name; 38 | value = normalizeValue value; 39 | }) themeProperties 40 | ); 41 | in 42 | { 43 | options.catppuccin.xfce4-terminal = catppuccinLib.mkCatppuccinOption { 44 | name = "xfce4-terminal"; 45 | useGlobalEnable = false; 46 | }; 47 | 48 | config = lib.mkIf enable { 49 | xfconf.settings = { 50 | xfce4-terminal = terminalSettings; 51 | }; 52 | }; 53 | } 54 | -------------------------------------------------------------------------------- /shell.nix: -------------------------------------------------------------------------------- 1 | { 2 | pkgs ? import { 3 | inherit system; 4 | config = { }; 5 | overlays = [ ]; 6 | }, 7 | system ? builtins.currentSystem, 8 | minimal ? false, 9 | }: 10 | 11 | pkgs.mkShellNoCC { 12 | packages = 13 | with pkgs; 14 | [ 15 | /* 16 | WARN(@getchoo): KEEP A SAFE NIX PINNED!! 17 | 18 | We end up relying on some features exclusive to Nix, like relative path inputs 19 | https://git.lix.systems/lix-project/lix/issues/641 20 | 21 | We also run into inconsistent evaluation with "distributions" of Nix 22 | and their features - like DetNix and Lazy Trees 23 | 24 | Basically: Nix is the only one that evaluates our development Flake correctly. Yay. 25 | */ 26 | nixVersions.nix_2_28 27 | 28 | # Node tooling for Astro/Starlight 29 | nodejs-slim_22 30 | corepack 31 | nrr 32 | ] 33 | ++ lib.optionals (!minimal) [ 34 | # Nix tools 35 | deadnix 36 | nixfmt-rfc-style 37 | nil 38 | statix 39 | 40 | # GHA lints 41 | actionlint 42 | 43 | # Python tools for paws.py 44 | pyright 45 | ruff 46 | 47 | # More node tooling for Astro/Starlight 48 | astro-language-server 49 | typescript-language-server 50 | 51 | # Shell lints 52 | shellcheck 53 | ]; 54 | 55 | shellHook = '' 56 | echo "Welcome to the catppuccin/nix repository! Thanks for contributing and have a wonderful day 🐈" 57 | ''; 58 | } 59 | -------------------------------------------------------------------------------- /modules/home-manager/tmux.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { 3 | config, 4 | lib, 5 | ... 6 | }: 7 | 8 | let 9 | cfg = config.catppuccin.tmux; 10 | in 11 | 12 | { 13 | options.catppuccin.tmux = catppuccinLib.mkCatppuccinOption { name = "tmux"; } // { 14 | extraConfig = lib.mkOption { 15 | type = lib.types.lines; 16 | description = "Additional configuration for the catppuccin plugin."; 17 | default = ""; 18 | example = '' 19 | set -g @catppuccin_status_modules_right "application session user host date_time" 20 | ''; 21 | }; 22 | }; 23 | 24 | imports = 25 | (catppuccinLib.mkRenamedCatppuccinOptions { 26 | from = [ 27 | "programs" 28 | "tmux" 29 | "catppuccin" 30 | ]; 31 | to = "tmux"; 32 | }) 33 | ++ [ 34 | (lib.mkRenamedOptionModule 35 | [ 36 | "programs" 37 | "tmux" 38 | "catppuccin" 39 | "extraConfig" 40 | ] 41 | [ 42 | "catppuccin" 43 | "tmux" 44 | "extraConfig" 45 | ] 46 | ) 47 | ]; 48 | 49 | config = lib.mkIf cfg.enable { 50 | programs.tmux = { 51 | plugins = [ 52 | { 53 | plugin = config.catppuccin.sources.tmux; 54 | extraConfig = lib.concatStrings [ 55 | '' 56 | set -g @catppuccin_flavor '${cfg.flavor}' 57 | '' 58 | cfg.extraConfig 59 | ]; 60 | } 61 | ]; 62 | }; 63 | }; 64 | } 65 | -------------------------------------------------------------------------------- /modules/home-manager/all-modules.nix: -------------------------------------------------------------------------------- 1 | [ 2 | # keep-sorted start 3 | ./aerc.nix 4 | ./alacritty.nix 5 | ./anki.nix 6 | ./atuin.nix 7 | ./bat.nix 8 | ./bottom.nix 9 | ./btop.nix 10 | ./cava.nix 11 | ./chrome.nix 12 | ./cursors.nix 13 | ./delta.nix 14 | ./dunst.nix 15 | ./element-desktop.nix 16 | ./eza.nix 17 | ./fcitx5.nix 18 | ./firefox.nix 19 | ./fish.nix 20 | ./foot.nix 21 | ./freetube.nix 22 | ./fuzzel.nix 23 | ./fzf.nix 24 | ./gh-dash.nix 25 | ./ghostty.nix 26 | ./gitui.nix 27 | ./glamour.nix 28 | ./gtk.nix 29 | ./halloy.nix 30 | ./helix.nix 31 | ./hyprland.nix 32 | ./hyprlock.nix 33 | ./imv.nix 34 | ./k9s.nix 35 | ./kitty.nix 36 | ./kvantum.nix 37 | ./lazygit.nix 38 | ./lsd.nix 39 | ./mako.nix 40 | ./mangohud.nix 41 | ./micro.nix 42 | ./mpv.nix 43 | ./neovim.nix 44 | ./newsboat.nix 45 | ./nushell.nix 46 | ./obs.nix 47 | ./polybar.nix 48 | ./qutebrowser.nix 49 | ./rio.nix 50 | ./rofi.nix 51 | ./sioyek.nix 52 | ./skim.nix 53 | ./spotify-player.nix 54 | ./starship.nix 55 | ./sway.nix 56 | ./swaylock.nix 57 | ./swaync.nix 58 | ./television.nix 59 | ./thunderbird.nix 60 | ./tmux.nix 61 | ./tofi.nix 62 | ./vesktop.nix 63 | ./vicinae.nix 64 | ./vivid.nix 65 | ./vscode.nix 66 | ./waybar.nix 67 | ./wezterm.nix 68 | ./wlogout.nix 69 | ./xfce4-terminal.nix 70 | ./yazi.nix 71 | ./zathura.nix 72 | ./zed-editor.nix 73 | ./zellij.nix 74 | ./zsh-syntax-highlighting.nix 75 | # keep-sorted end 76 | ] 77 | -------------------------------------------------------------------------------- /modules/home-manager/neovim.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | let 4 | cfg = config.catppuccin.nvim; 5 | 6 | defaultConfig = { 7 | compile_path = lib.generators.mkLuaInline "compile_path"; 8 | flavour = cfg.flavor; 9 | }; 10 | in 11 | { 12 | options.catppuccin.nvim = catppuccinLib.mkCatppuccinOption { name = "neovim"; } // { 13 | settings = lib.mkOption { 14 | description = "Extra settings that will be passed to the setup function."; 15 | default = { }; 16 | type = lib.types.submodule { freeformType = lib.types.attrsOf lib.types.anything; }; 17 | apply = lib.recursiveUpdate defaultConfig; 18 | }; 19 | }; 20 | 21 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 22 | from = [ 23 | "programs" 24 | "neovim" 25 | "catppuccin" 26 | ]; 27 | to = "nvim"; 28 | }; 29 | 30 | config = lib.mkIf cfg.enable { 31 | programs.neovim = { 32 | plugins = [ 33 | { 34 | plugin = config.catppuccin.sources.nvim; 35 | config = '' 36 | lua << EOF 37 | local compile_path = vim.fn.stdpath("cache") .. "/catppuccin-nvim" 38 | vim.fn.mkdir(compile_path, "p") 39 | vim.opt.runtimepath:append(compile_path) 40 | 41 | require("catppuccin").setup(${lib.generators.toLua { } cfg.settings}) 42 | 43 | vim.api.nvim_command("colorscheme catppuccin") 44 | EOF 45 | ''; 46 | } 47 | ]; 48 | }; 49 | }; 50 | } 51 | -------------------------------------------------------------------------------- /modules/nixos/cursors.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { 3 | config, 4 | lib, 5 | ... 6 | }: 7 | 8 | let 9 | inherit (config.catppuccin) sources; 10 | 11 | cfg = config.catppuccin.cursors; 12 | 13 | # "dark" and "light" can be used alongside the regular accents 14 | cursorAccentType = lib.types.mergeTypes catppuccinLib.types.accent ( 15 | lib.types.enum [ 16 | "dark" 17 | "light" 18 | ] 19 | ); 20 | in 21 | 22 | { 23 | options.catppuccin.cursors = 24 | (catppuccinLib.mkCatppuccinOption { 25 | name = "pointer cursors"; 26 | # NOTE: We exclude this as there is no `enable` option in the upstream 27 | # module to guard it 28 | useGlobalEnable = false; 29 | }) 30 | // { 31 | accent = lib.mkOption { 32 | type = cursorAccentType; 33 | default = config.catppuccin.accent; 34 | description = "Catppuccin accent for pointer cursors"; 35 | }; 36 | }; 37 | 38 | config = 39 | lib.mkIf 40 | ( 41 | cfg.enable 42 | && (config.services.desktopManager.gnome.enable || config.services.displayManager.gdm.enable) 43 | ) 44 | { 45 | environment.systemPackages = [ 46 | sources.cursors 47 | ]; 48 | 49 | programs.dconf.profiles.gdm.databases = [ 50 | { 51 | lockAll = true; 52 | settings."org/gnome/desktop/interface" = { 53 | cursor-theme = "catppuccin-${cfg.flavor}-${cfg.accent}-cursors"; 54 | }; 55 | } 56 | ]; 57 | }; 58 | } 59 | -------------------------------------------------------------------------------- /modules/home-manager/thunderbird.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { 3 | config, 4 | lib, 5 | pkgs, 6 | ... 7 | }: 8 | 9 | let 10 | inherit (config.catppuccin) sources; 11 | cfg = config.catppuccin.thunderbird; 12 | enable = cfg.enable && config.programs.thunderbird.enable; 13 | in 14 | { 15 | options.catppuccin.thunderbird = 16 | catppuccinLib.mkCatppuccinOption { 17 | name = "thunderbird"; 18 | accentSupport = true; 19 | } 20 | // { 21 | profile = lib.mkOption { 22 | type = lib.types.str; 23 | default = "catppuccin-${cfg.flavor}-${cfg.accent}"; 24 | description = "The profile name"; 25 | }; 26 | }; 27 | 28 | config = lib.mkIf enable { 29 | programs.thunderbird = { 30 | profiles."${cfg.profile}".extensions = [ 31 | (pkgs.runCommandLocal "catppuccin-${cfg.flavor}-${cfg.accent}.thunderbird.theme" 32 | { 33 | buildInputs = [ sources.thunderbird ]; 34 | nativeBuildInputs = with pkgs; [ 35 | jq 36 | unzip 37 | ]; 38 | } 39 | '' 40 | xpi=${sources.thunderbird}/${cfg.flavor}/${cfg.flavor}-${cfg.accent}.xpi 41 | extId=$(unzip -qc $xpi manifest.json | jq -r .applications.gecko.id) 42 | # The extensions path shared by all profiles. 43 | extensionPath="extensions/{ec8030f7-c20a-464f-9b0e-13a3a9e97384}" 44 | install -Dv $xpi $out/share/mozilla/$extensionPath/$extId.xpi 45 | '' 46 | ) 47 | ]; 48 | }; 49 | }; 50 | } 51 | -------------------------------------------------------------------------------- /modules/home-manager/lazygit.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { 3 | config, 4 | lib, 5 | pkgs, 6 | ... 7 | }: 8 | 9 | let 10 | inherit (config.catppuccin) sources; 11 | 12 | cfg = config.catppuccin.lazygit; 13 | enable = cfg.enable && config.programs.lazygit.enable; 14 | 15 | # NOTE: On MacOS specifically, lazygit expects its configuration to be in 16 | # `~/Library/Application Support` when not using XDG 17 | enableXdgConfig = !pkgs.stdenv.hostPlatform.isDarwin || config.xdg.enable; 18 | 19 | configDirectory = 20 | if enableXdgConfig then 21 | config.xdg.configHome 22 | else 23 | "${config.home.homeDirectory}/Library/Application Support"; 24 | configFile = "${configDirectory}/lazygit/config.yml"; 25 | in 26 | 27 | { 28 | options.catppuccin.lazygit = catppuccinLib.mkCatppuccinOption { 29 | name = "lazygit"; 30 | accentSupport = true; 31 | }; 32 | 33 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 34 | from = [ 35 | "programs" 36 | "lazygit" 37 | "catppuccin" 38 | ]; 39 | to = "lazygit"; 40 | accentSupport = true; 41 | }; 42 | 43 | config = lib.mkIf enable { 44 | home.sessionVariables = 45 | let 46 | configFiles = [ 47 | "${sources.lazygit}/${cfg.flavor}/${cfg.accent}.yml" 48 | ] 49 | ++ lib.optional (config.programs.lazygit.settings != { }) configFile; 50 | in 51 | { 52 | # Ensure that the default config file is still sourced 53 | LG_CONFIG_FILE = lib.concatStringsSep "," configFiles; 54 | }; 55 | }; 56 | } 57 | -------------------------------------------------------------------------------- /modules/home-manager/zed-editor.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.zed; 8 | enable = cfg.enable && config.programs.zed-editor.enable; 9 | 10 | accent = if cfg.accent == "mauve" then "" else " (${cfg.accent})"; 11 | flavor = catppuccinLib.mkFlavorName cfg.flavor; 12 | in 13 | 14 | { 15 | options.catppuccin.zed = 16 | catppuccinLib.mkCatppuccinOption { 17 | name = "zed"; 18 | accentSupport = true; 19 | } 20 | // { 21 | italics = lib.mkEnableOption "the italicized version of theme" // { 22 | default = true; 23 | }; 24 | 25 | icons = catppuccinLib.mkCatppuccinOption { 26 | name = "zed icons"; 27 | }; 28 | }; 29 | 30 | config = lib.mkIf enable { 31 | programs.zed-editor = { 32 | extensions = lib.optionals cfg.icons.enable [ "catppuccin-icons" ]; 33 | userSettings = { 34 | icon_theme = lib.mkIf cfg.icons.enable ( 35 | "Catppuccin " + (catppuccinLib.mkFlavorName cfg.icons.flavor) 36 | ); 37 | theme = { 38 | light = "Catppuccin " + flavor + accent + lib.optionalString (!cfg.italics) " - No Italics"; 39 | dark = "Catppuccin " + flavor + accent + lib.optionalString (!cfg.italics) " - No Italics"; 40 | }; 41 | }; 42 | }; 43 | 44 | xdg.configFile = { 45 | "zed/themes/catppuccin.json".source = "${sources.zed}/catppuccin-${ 46 | lib.optionalString (!cfg.italics) "no-italics-" 47 | }${cfg.accent}.json"; 48 | }; 49 | }; 50 | } 51 | -------------------------------------------------------------------------------- /modules/home-manager/dunst.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.dunst; 8 | enable = cfg.enable && config.services.dunst.enable; 9 | in 10 | 11 | { 12 | options.catppuccin.dunst = catppuccinLib.mkCatppuccinOption { name = "dunst"; } // { 13 | prefix = lib.mkOption { 14 | type = lib.types.str; 15 | default = "00"; 16 | description = "Prefix to use for the dunst drop-in file"; 17 | }; 18 | }; 19 | 20 | imports = 21 | (catppuccinLib.mkRenamedCatppuccinOptions { 22 | from = [ 23 | "services" 24 | "dunst" 25 | "catppuccin" 26 | ]; 27 | to = "dunst"; 28 | }) 29 | ++ [ 30 | (lib.mkRenamedOptionModule 31 | [ 32 | "services" 33 | "dunst" 34 | "catppuccin" 35 | "prefix" 36 | ] 37 | [ 38 | "catppuccin" 39 | "dunst" 40 | "prefix" 41 | ] 42 | ) 43 | ]; 44 | 45 | # Dunst currently has no "include" functionality, but has "drop-ins" 46 | # Unfortunately, this may cause inconvenience as it overrides ~/.config/dunst/dunstrc 47 | # but it can be overridden by another drop-in. 48 | config = lib.mkIf enable { 49 | xdg.configFile = { 50 | # Using a prefix like this is necessary because drop-ins' precedence depends on lexical order 51 | # such that later drop-ins override earlier ones 52 | # This way, users have better control over precedence 53 | "dunst/dunstrc.d/${cfg.prefix}-catppuccin.conf".source = sources.dunst + "/${cfg.flavor}.conf"; 54 | }; 55 | }; 56 | } 57 | -------------------------------------------------------------------------------- /docs/content/docs/FAQ.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Frequently Asked Questions 3 | description: Find the most common issues and questions about catppuccin/nix 4 | --- 5 | 6 | Here we keep a list of common issues and questions, and all the answers to 7 | them. Feel free to add more! 8 | 9 | ## How do I know what programs are supported? 10 | 11 | You can find programs supported through home-manager 12 | [here](https://nix.catppuccin.com/options/main/home/catppuccin/), and NixOS 13 | modules [here](https://nix.catppuccin.com/options/main/nixos/catppuccin/). 14 | 15 | ## How do I set `catppuccin.enable` for everything I use? 16 | 17 | You can set `catppuccin.enable` globally through home-manager 18 | [here](/options/main/home/catppuccin/#catppuccin-enable), and NixOS modules 19 | [here](/options/main/nixos/catppuccin/#catppuccin-enable). 20 | 21 | ## What versions of NixOS and home-manager are supported? 22 | 23 | We support both the `unstable` branch and latest stable. This is done through two branches in our repository: 24 | 25 | - `main`: for unstable users 26 | - `release-x.x`: for the latest stable release (i.e., `release-25.05`) 27 | 28 | ## How do I fix the error: `... during evaluation because the option 'allow-import-from-derivation' is disabled` 29 | 30 | Some ports need to read and/or manipulate remote resources, resulting in Nix 31 | performing 32 | [IFD](https://nix.dev/manual/nix/latest/language/import-from-derivation). We 33 | try to avoid this where possible, but sometimes we need to use it. Check out 34 | [our tracking issue](https://github.com/catppuccin/nix/issues/392) to see what 35 | ports are affected. 36 | 37 | ## How do I fix the error: `a '...' with features {} is required to build '...'`? 38 | 39 | See the above 40 | -------------------------------------------------------------------------------- /modules/global.nix: -------------------------------------------------------------------------------- 1 | { catppuccinModules }: 2 | { 3 | config, 4 | lib, 5 | pkgs, 6 | ... 7 | }: 8 | 9 | let 10 | catppuccinLib = import ./lib { inherit config lib pkgs; }; 11 | in 12 | 13 | { 14 | config = { 15 | assertions = [ (catppuccinLib.assertMinimumVersion "25.05") ]; 16 | }; 17 | 18 | imports = catppuccinLib.applyToModules catppuccinModules; 19 | 20 | options.catppuccin = { 21 | enable = lib.mkEnableOption "Catppuccin globally"; 22 | 23 | flavor = lib.mkOption { 24 | type = catppuccinLib.types.flavor; 25 | default = "mocha"; 26 | description = "Global Catppuccin flavor"; 27 | }; 28 | 29 | accent = lib.mkOption { 30 | type = catppuccinLib.types.accent; 31 | default = "mauve"; 32 | description = "Global Catppuccin accent"; 33 | }; 34 | 35 | sources = 36 | let 37 | defaultSources = (import ../default.nix { inherit pkgs; }).packages; 38 | in 39 | lib.mkOption { 40 | type = lib.types.lazyAttrsOf lib.types.raw; 41 | default = defaultSources; 42 | defaultText = "{ ... }"; 43 | # HACK! 44 | # without this, overriding one source will delete all others. -@getchoo 45 | apply = lib.recursiveUpdate defaultSources; 46 | description = "Port sources used across all options"; 47 | }; 48 | 49 | cache.enable = lib.mkEnableOption "the usage of Catppuccin's binary cache"; 50 | }; 51 | 52 | config = { 53 | nix.settings = lib.mkIf config.catppuccin.cache.enable { 54 | extra-substituters = [ "https://catppuccin.cachix.org" ]; 55 | extra-trusted-public-keys = [ 56 | "catppuccin.cachix.org-1:noG/4HkbhJb+lUAdKrph6LaozJvAeEEZj4N732IysmU=" 57 | ]; 58 | }; 59 | }; 60 | } 61 | -------------------------------------------------------------------------------- /pkgs/vscode/package.nix: -------------------------------------------------------------------------------- 1 | { 2 | lib, 3 | vscode-utils, 4 | fetchCatppuccinPort, 5 | nodejs_22, 6 | pnpm_10, 7 | 8 | catppuccinOptions ? { }, 9 | }: 10 | 11 | let 12 | 13 | nodejs = nodejs_22; 14 | pnpm = pnpm_10.override { inherit nodejs; }; 15 | 16 | in 17 | 18 | vscode-utils.buildVscodeExtension (finalAttrs: { 19 | pname = "catppuccin-vscode"; 20 | name = finalAttrs.pname; 21 | version = "3.18.0"; 22 | 23 | src = fetchCatppuccinPort { 24 | port = "vscode"; 25 | rev = "refs/tags/@catppuccin/vscode-v${finalAttrs.version}"; 26 | hash = "sha256-vi+QNploStQFrXSc+izcycKtpkrRsq2mJWrKsHP3D5g="; 27 | }; 28 | 29 | vscodeExtPublisher = "catppuccin"; 30 | vscodeExtName = "vscode"; 31 | vscodeExtUniqueId = "catppuccin.vscode"; 32 | 33 | sourceRoot = null; 34 | 35 | pnpmWorkspaces = [ "catppuccin-vsc" ]; 36 | pnpmDeps = pnpm.fetchDeps { 37 | inherit (finalAttrs) 38 | pname 39 | version 40 | src 41 | pnpmWorkspaces 42 | ; 43 | fetcherVersion = 2; 44 | hash = "sha256-uwc1QtP3Orh8iAS0g9PNfOIkadJgZKflBvSvpIXN3T8="; 45 | }; 46 | 47 | nativeBuildInputs = [ 48 | nodejs 49 | pnpm.configHook 50 | ]; 51 | 52 | env = lib.optionalAttrs (catppuccinOptions != { }) { 53 | CATPPUCCIN_OPTIONS = builtins.toJSON catppuccinOptions; 54 | }; 55 | 56 | buildPhase = '' 57 | runHook preBuild 58 | 59 | pnpm --filter catppuccin-vsc core:build --no-regenerate 60 | 61 | cd packages/catppuccin-vsc 62 | node dist/hooks/generateThemes.cjs 63 | touch ./themes/.flag 64 | 65 | runHook postBuild 66 | ''; 67 | 68 | installPhase = '' 69 | runHook preInstall 70 | 71 | mkdir -p "$out/$installPrefix" 72 | cp -rL ../../LICENSE ../../README.md package.json icon.png dist/ themes/ "$out/$installPrefix/" 73 | 74 | runHook postInstall 75 | ''; 76 | }) 77 | -------------------------------------------------------------------------------- /modules/home-manager/freetube.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (lib) toSentenceCase; 6 | cfg = config.catppuccin.freetube; 7 | in 8 | 9 | { 10 | options.catppuccin.freetube = 11 | catppuccinLib.mkCatppuccinOption { 12 | name = "freetube"; 13 | accentSupport = true; 14 | } 15 | // { 16 | # FreeTube supports two accent colors 17 | secondaryAccent = lib.mkOption { 18 | type = catppuccinLib.types.accent; 19 | # Have the secondary accent default to FreeTube's main accent rather than the global Catppuccin accent 20 | # This assumes most users would prefer both accent colors to be the same when only overriding the main one 21 | default = cfg.accent; 22 | description = "Secondary accent for freetube"; 23 | }; 24 | }; 25 | 26 | imports = 27 | (catppuccinLib.mkRenamedCatppuccinOptions { 28 | from = [ 29 | "programs" 30 | "freetube" 31 | "catppuccin" 32 | ]; 33 | to = "freetube"; 34 | accentSupport = true; 35 | }) 36 | ++ [ 37 | (lib.mkRenamedOptionModule 38 | [ 39 | "programs" 40 | "freetube" 41 | "catppuccin" 42 | "secondaryAccent" 43 | ] 44 | [ 45 | "catppuccin" 46 | "freetube" 47 | "secondaryAccent" 48 | ] 49 | ) 50 | ]; 51 | 52 | config = lib.mkIf cfg.enable { 53 | programs.freetube.settings = { 54 | # NOTE: For some reason, baseTheme does not capitalize first letter, but the other settings do 55 | baseTheme = "catppuccin${toSentenceCase cfg.flavor}"; 56 | mainColor = "Catppuccin${toSentenceCase cfg.flavor}${toSentenceCase cfg.accent}"; 57 | secColor = "Catppuccin${toSentenceCase cfg.flavor}${toSentenceCase cfg.secondaryAccent}"; 58 | }; 59 | }; 60 | } 61 | -------------------------------------------------------------------------------- /modules/home-manager/wlogout.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.wlogout; 8 | in 9 | 10 | { 11 | options.catppuccin.wlogout = 12 | catppuccinLib.mkCatppuccinOption { 13 | name = "wlogout"; 14 | accentSupport = true; 15 | } 16 | // { 17 | iconStyle = lib.mkOption { 18 | type = lib.types.enum [ 19 | "wlogout" 20 | "wleave" 21 | ]; 22 | description = "Icon style to set in ~/.config/wlogout/style.css"; 23 | default = "wlogout"; 24 | example = lib.literalExpression "wleave"; 25 | }; 26 | extraStyle = lib.mkOption { 27 | type = lib.types.lines; 28 | description = "Additional CSS to put in ~/.config/wlogout/style.css"; 29 | default = ""; 30 | example = lib.literalExpression '' 31 | button { 32 | border-radius: 2px; 33 | } 34 | 35 | #lock { 36 | background-image: url("''${config.gtk.iconTheme.package}/share/icons/''${config.gtk.iconTheme.name}/apps/scalable/system-lock-screen.svg"); 37 | } 38 | ''; 39 | }; 40 | }; 41 | 42 | config = lib.mkIf cfg.enable { 43 | programs.wlogout.style = lib.concatStrings [ 44 | '' 45 | @import url("${sources.wlogout}/themes/${cfg.flavor}/${cfg.accent}.css"); 46 | '' 47 | (lib.concatMapStrings 48 | (icon: '' 49 | #${icon} { 50 | background-image: url("${sources.wlogout}/icons/${cfg.iconStyle}/${cfg.flavor}/${cfg.accent}/${icon}.svg"); 51 | } 52 | '') 53 | [ 54 | "hibernate" 55 | "lock" 56 | "logout" 57 | "reboot" 58 | "shutdown" 59 | "suspend" 60 | ] 61 | ) 62 | cfg.extraStyle 63 | ]; 64 | }; 65 | } 66 | -------------------------------------------------------------------------------- /modules/home-manager/k9s.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { 3 | config, 4 | lib, 5 | pkgs, 6 | ... 7 | }: 8 | 9 | let 10 | inherit (config.catppuccin) sources; 11 | 12 | cfg = config.catppuccin.k9s; 13 | enable = cfg.enable && config.programs.k9s.enable; 14 | 15 | # NOTE: On MacOS specifically, k9s expects its configuration to be in 16 | # `~/Library/Application Support` when not using XDG 17 | enableXdgConfig = !pkgs.stdenv.hostPlatform.isDarwin || config.xdg.enable; 18 | 19 | themeName = "catppuccin-${cfg.flavor}" + lib.optionalString cfg.transparent "-transparent"; 20 | themeFile = "${themeName}.yaml"; 21 | themePath = "k9s/skins/${themeFile}"; 22 | theme = sources.k9s + "/${themeFile}"; 23 | in 24 | 25 | { 26 | options.catppuccin.k9s = catppuccinLib.mkCatppuccinOption { name = "k9s"; } // { 27 | transparent = lib.mkEnableOption "transparent version of flavor"; 28 | }; 29 | 30 | imports = 31 | (catppuccinLib.mkRenamedCatppuccinOptions { 32 | from = [ 33 | "programs" 34 | "k9s" 35 | "catppuccin" 36 | ]; 37 | to = "k9s"; 38 | }) 39 | ++ [ 40 | (lib.mkRenamedOptionModule 41 | [ 42 | "programs" 43 | "k9s" 44 | "catppuccin" 45 | "transparent" 46 | ] 47 | [ 48 | "catppuccin" 49 | "k9s" 50 | "transparent" 51 | ] 52 | ) 53 | ]; 54 | 55 | config = lib.mkIf enable ( 56 | lib.mkMerge [ 57 | (lib.mkIf (!enableXdgConfig) { 58 | home.file = { 59 | "Library/Application Support/${themePath}".source = theme; 60 | }; 61 | }) 62 | 63 | (lib.mkIf enableXdgConfig { xdg.configFile.${themePath}.source = theme; }) 64 | 65 | { 66 | programs.k9s = { 67 | settings = { 68 | k9s.ui.skin = themeName; 69 | }; 70 | }; 71 | } 72 | ] 73 | ); 74 | } 75 | -------------------------------------------------------------------------------- /modules/home-manager/waybar.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.waybar; 8 | enable = cfg.enable && config.programs.waybar.enable; 9 | 10 | styleFile = "${sources.waybar}/${cfg.flavor}.css"; 11 | in 12 | 13 | { 14 | options.catppuccin.waybar = catppuccinLib.mkCatppuccinOption { name = "waybar"; } // { 15 | mode = lib.mkOption { 16 | type = lib.types.enum [ 17 | "prependImport" 18 | "createLink" 19 | ]; 20 | default = "prependImport"; 21 | description = '' 22 | Defines how to include the catppuccin theme css file: 23 | 24 | - `prependImport`: Prepends the import statement, if `programs.waybar.style` is a string (with default override priority). 25 | - `createLink`: Creates a symbolic link `~/.config/waybar/catppuccin.css`, which needs to be included in the waybar stylesheet. 26 | ''; 27 | }; 28 | }; 29 | 30 | imports = 31 | (catppuccinLib.mkRenamedCatppuccinOptions { 32 | from = [ 33 | "programs" 34 | "waybar" 35 | "catppuccin" 36 | ]; 37 | to = "waybar"; 38 | }) 39 | ++ [ 40 | (lib.mkRenamedOptionModule 41 | [ 42 | "programs" 43 | "waybar" 44 | "catppuccin" 45 | "mode" 46 | ] 47 | [ 48 | "catppuccin" 49 | "waybar" 50 | "mode" 51 | ] 52 | ) 53 | ]; 54 | 55 | config = lib.mkIf enable ( 56 | lib.mkMerge [ 57 | (lib.mkIf (cfg.mode == "prependImport") { 58 | programs.waybar = { 59 | style = lib.mkBefore '' 60 | @import "${styleFile}"; 61 | ''; 62 | }; 63 | }) 64 | 65 | (lib.mkIf (cfg.mode == "createLink") { 66 | xdg.configFile = { 67 | "waybar/catppuccin.css".source = styleFile; 68 | }; 69 | }) 70 | ] 71 | ); 72 | } 73 | -------------------------------------------------------------------------------- /modules/home-manager/swaylock.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.swaylock; 8 | in 9 | 10 | { 11 | options.catppuccin.swaylock = catppuccinLib.mkCatppuccinOption { 12 | name = "swaylock"; 13 | /* 14 | global `catppuccin.enable` purposefully doesn't work here in configurations with a `home.stateVersion` 15 | that is >= 23.05 16 | this is because the upstream module will automatically enable itself if `programs.swaylock.settings` 17 | is set in configurations with a `home.stateVersion` that is < 23.05. so, we can't use the 18 | `programs.swaylock.enable` option to guard against defining this like we usually do, as when the 19 | upstream `enable` option is unset on these systems it checks that same `settings` option we would be 20 | defining if *our* and the upstream's `enable` option is `true` ...leading to a case of infinite 21 | recursion where `programs.swaylock.settings` is only being defined if `programs.swaylock.settings` is 22 | defined 23 | debugging this was the most confusing and horrifying thing i've had to deal with throughout working on 24 | this project. 25 | - @getchoo 26 | */ 27 | default = lib.versionAtLeast config.home.stateVersion "23.05" && config.catppuccin.enable; 28 | defaultText = lib.literalExpression '' 29 | `catppuccin.enable` if `home.stateVersion` is >= 23.05, false otherwise 30 | Yes this is weird, and there's a funny story about it in the code comments 31 | ''; 32 | }; 33 | 34 | imports = catppuccinLib.mkRenamedCatppuccinOptions { 35 | from = [ 36 | "programs" 37 | "swaylock" 38 | "catppuccin" 39 | ]; 40 | to = "swaylock"; 41 | }; 42 | 43 | config = lib.mkIf cfg.enable { 44 | programs.swaylock = { 45 | settings = catppuccinLib.importINI (sources.swaylock + "/${cfg.flavor}.conf"); 46 | }; 47 | }; 48 | } 49 | -------------------------------------------------------------------------------- /modules/home-manager/kvantum.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { 3 | config, 4 | lib, 5 | ... 6 | }: 7 | 8 | let 9 | cfg = config.catppuccin.kvantum; 10 | enable = cfg.enable && config.qt.enable; 11 | 12 | themeName = "catppuccin-${cfg.flavor}-${cfg.accent}"; 13 | in 14 | 15 | { 16 | options.catppuccin.kvantum = 17 | catppuccinLib.mkCatppuccinOption { 18 | name = "Kvantum"; 19 | accentSupport = true; 20 | } 21 | // { 22 | apply = lib.mkOption { 23 | type = lib.types.bool; 24 | default = true; 25 | description = '' 26 | Applies the theme by overwriting `$XDG_CONFIG_HOME/Kvantum/kvantum.kvconfig`. 27 | If this is disabled, you must manually set the theme (e.g. by using `kvantummanager`). 28 | ''; 29 | }; 30 | }; 31 | 32 | imports = 33 | (catppuccinLib.mkRenamedCatppuccinOptions { 34 | from = [ 35 | "qt" 36 | "style" 37 | "catppuccin" 38 | ]; 39 | to = "kvantum"; 40 | accentSupport = true; 41 | }) 42 | ++ [ 43 | (lib.mkRenamedOptionModule 44 | [ 45 | "qt" 46 | "style" 47 | "catppuccin" 48 | "apply" 49 | ] 50 | [ 51 | "catppuccin" 52 | "kvantum" 53 | "apply" 54 | ] 55 | ) 56 | ]; 57 | 58 | config = lib.mkIf enable { 59 | assertions = [ 60 | { 61 | assertion = lib.elem config.qt.style.name [ 62 | "kvantum" 63 | "Kvantum" 64 | ]; 65 | message = ''`qt.style.name` must be `"kvantum"` to use `qt.style.catppuccin`''; 66 | } 67 | ]; 68 | 69 | xdg.configFile = { 70 | "Kvantum/${themeName}".source = "${config.catppuccin.sources.kvantum}/share/Kvantum/${themeName}"; 71 | "Kvantum/kvantum.kvconfig" = lib.mkIf cfg.apply { 72 | text = '' 73 | [General] 74 | theme=${themeName} 75 | ''; 76 | }; 77 | }; 78 | }; 79 | } 80 | -------------------------------------------------------------------------------- /docs/pages/options/[version]/[type]/[module].astro: -------------------------------------------------------------------------------- 1 | --- 2 | import AnchorHeading from "@astrojs/starlight/components/AnchorHeading.astro"; 3 | import StarlightPage from "@astrojs/starlight/components/StarlightPage.astro"; 4 | 5 | import { optionsData } from "@data/options.ts"; 6 | 7 | interface Props { 8 | version: string; 9 | type: string; 10 | module: string; 11 | } 12 | 13 | export const getStaticPaths = () => 14 | Object.entries(optionsData).flatMap(([version, modules]) => 15 | Object.entries(modules).flatMap(([type, options]) => 16 | Object.keys(options).map((module) => { 17 | const params = { params: { version, type, module } }; 18 | return params; 19 | }), 20 | ), 21 | ); 22 | 23 | const { version, type, module } = Astro.params; 24 | const moduleData = optionsData[version]?.[type]?.[module]; 25 | 26 | // Find the filename from a link like `https://github.com/catppuccin/nix/blob/8bfcb715e9b3cfaa2bee8da8d5c877115963ee27/modules/global.nix` 27 | const filenameFromLink = (link: string): string => { 28 | const linkBase = "https://github.com/catppuccin/nix/blob/"; 29 | // Git SHAs are 40 characters long 30 | return link.substring(linkBase.length + 41, link.length); 31 | }; 32 | --- 33 | 34 | 41 |

Options for the {module} module.

42 | 43 | { 44 | moduleData.map(([optionName, data]) => ( 45 | <> 46 | 47 | {optionName} 48 | 49 | 50 |

{data.description}

51 | 52 |

53 | Type: {data.type} 54 |

55 | 56 |

57 | Default: {data.default.text} 58 |

59 | 60 |

61 | Declared in:{" "} 62 | 63 | {filenameFromLink(data.declarations[0])} 64 | 65 |

66 | 67 | )) 68 | } 69 | 70 | -------------------------------------------------------------------------------- /pkgs/sddm/package.nix: -------------------------------------------------------------------------------- 1 | { 2 | lib, 3 | buildCatppuccinPort, 4 | bash, 5 | just, 6 | whiskers, 7 | kdePackages, 8 | background ? null, 9 | font ? "Noto Sans", 10 | fontSize ? "9", 11 | loginBackground ? false, 12 | userIcon ? false, 13 | clockEnabled ? true, 14 | }: 15 | 16 | buildCatppuccinPort (finalAttrs: { 17 | port = "sddm"; 18 | 19 | postPatch = '' 20 | substituteInPlace justfile \ 21 | --replace-fail '#!/usr/bin/env bash' '#!${lib.getExe bash}' \ 22 | 23 | substituteInPlace src/theme.conf \ 24 | --replace-fail 'Font="Noto Sans"' 'Font="${font}"' \ 25 | --replace-fail 'FontSize=9' 'FontSize=${toString fontSize}' 26 | '' 27 | + lib.optionalString (background != null) '' 28 | substituteInPlace src/theme.conf \ 29 | --replace-fail 'Background="backgrounds/wall.png"' 'Background="${background}"' 30 | '' 31 | + lib.optionalString (background == null) '' 32 | substituteInPlace src/theme.conf \ 33 | --replace-fail 'CustomBackground="true"' 'CustomBackground="false"' 34 | '' 35 | + lib.optionalString loginBackground '' 36 | substituteInPlace src/theme.conf \ 37 | --replace-fail 'LoginBackground="false"' 'LoginBackground="true"' 38 | '' 39 | + lib.optionalString userIcon '' 40 | substituteInPlace src/theme.conf \ 41 | --replace-fail 'UserIcon="false"' 'UserIcon="true"' 42 | '' 43 | + lib.optionalString (!clockEnabled) '' 44 | substituteInPlace src/theme.conf \ 45 | --replace-fail 'ClockEnabled="true"' 'ClockEnabled="false"' 46 | ''; 47 | 48 | nativeBuildInputs = [ 49 | just 50 | whiskers 51 | ]; 52 | 53 | propagatedBuildInputs = [ 54 | kdePackages.qtsvg 55 | ]; 56 | 57 | dontCatppuccinInstall = true; 58 | 59 | dontWrapQtApps = true; 60 | 61 | buildPhase = '' 62 | runHook preBuild 63 | just build 64 | runHook postBuild 65 | ''; 66 | 67 | installPhase = '' 68 | runHook preInstall 69 | 70 | mkdir -p $out/share/sddm 71 | mv themes $out/share/sddm/ 72 | 73 | runHook postInstall 74 | ''; 75 | 76 | postFixup = '' 77 | mkdir -p $out/nix-support 78 | echo ${kdePackages.qtsvg} >> $out/nix-support/propagated-user-env-packages 79 | ''; 80 | 81 | meta = { 82 | platforms = lib.platforms.linux; 83 | }; 84 | }) 85 | -------------------------------------------------------------------------------- /.github/workflows/ci.yml: -------------------------------------------------------------------------------- 1 | name: CI 2 | 3 | on: 4 | push: 5 | branches: 6 | - "main" 7 | - "release-*" 8 | paths: 9 | - "**.nix" 10 | - "flake.lock" 11 | 12 | - "pkgs/**" 13 | 14 | - ".github/workflows/ci.yml" 15 | pull_request: 16 | branches: 17 | - "main" 18 | - "release-*" 19 | paths: 20 | - "**.nix" 21 | - "flake.lock" 22 | 23 | - "pkgs/**" 24 | 25 | - ".github/workflows/ci.yml" 26 | workflow_dispatch: 27 | 28 | jobs: 29 | flake: 30 | name: Run Flake checks (${{ matrix.system }}) 31 | 32 | strategy: 33 | fail-fast: false 34 | matrix: 35 | include: 36 | - os: macos-latest 37 | system: aarch64-darwin 38 | - os: ubuntu-latest 39 | system: x86_64-linux 40 | 41 | os: [macos-latest, ubuntu-latest] 42 | 43 | runs-on: ${{ matrix.os }} 44 | 45 | steps: 46 | - name: Maximize Space 47 | uses: easimon/maximize-build-space@v10 48 | if: ${{ matrix.os != 'macos-latest' }} 49 | with: 50 | overprovision-lvm: true 51 | remove-android: true 52 | remove-dotnet: true 53 | remove-codeql: true 54 | remove-haskell: true 55 | remove-docker-images: true 56 | 57 | - name: Checkout repository 58 | uses: actions/checkout@v6 59 | 60 | - name: Install Nix 61 | uses: cachix/install-nix-action@v31 62 | 63 | - name: Install Cachix 64 | uses: cachix/cachix-action@v16 65 | with: 66 | name: catppuccin 67 | authToken: ${{ secrets.CACHIX_AUTH_TOKEN }} 68 | 69 | - name: Run tests 70 | env: 71 | SYSTEM: ${{ matrix.system }} 72 | # Some modules require IFD, so only evaluate for the current system 73 | run: | 74 | nix run \ 75 | --inputs-from . \ 76 | nixpkgs#nix-fast-build -- \ 77 | --skip-cached --no-nom \ 78 | --flake "./dev#checks.$SYSTEM" 79 | 80 | release-gate: 81 | name: Release Gate 82 | needs: [flake] 83 | 84 | runs-on: ubuntu-latest 85 | 86 | steps: 87 | - name: Exit with error 88 | if: ${{ contains(needs.*.result, 'failure') || contains(needs.*.result, 'cancelled') }} 89 | run: exit 1 90 | -------------------------------------------------------------------------------- /.github/workflows/website.yml: -------------------------------------------------------------------------------- 1 | name: Build & deploy website 2 | 3 | on: 4 | push: 5 | branches: [main] 6 | paths: 7 | - "**.lock" 8 | - "**.nix" 9 | - "docs/**" 10 | - "modules/**" 11 | 12 | - "package.json" 13 | - "pnpm-lock.yaml" 14 | - "tsconfig.json" 15 | - "astro.config.ts" 16 | 17 | - ".github/workflows/website.yml" 18 | pull_request: 19 | branches: [main] 20 | paths: 21 | - "**.lock" 22 | - "**.nix" 23 | - "docs/**" 24 | - "modules/**" 25 | 26 | - "package.json" 27 | - "pnpm-lock.yaml" 28 | - "tsconfig.json" 29 | - "astro.config.ts" 30 | 31 | - ".github/workflows/website.yml" 32 | workflow_dispatch: 33 | inputs: 34 | deploy: 35 | description: Whether to deploy the website after building 36 | required: false 37 | default: false 38 | type: boolean 39 | 40 | jobs: 41 | build: 42 | name: Build site 43 | 44 | runs-on: ubuntu-latest 45 | 46 | steps: 47 | - name: Checkout repository 48 | uses: actions/checkout@v6 49 | 50 | - name: Install Nix 51 | uses: cachix/install-nix-action@v31 52 | 53 | - name: Update options data 54 | run: | 55 | ./dev/update-docs-data.sh main 56 | ./dev/update-docs-data.sh 25.05 "github:catppuccin/nix/release-25.05?dir=dev/" 57 | 58 | - name: Install dependencies 59 | run: | 60 | nix develop .#ci --command pnpm install 61 | 62 | - name: Run build 63 | run: | 64 | nix develop .#ci --command nrr build 65 | 66 | - name: Upload Pages artifact 67 | uses: actions/upload-pages-artifact@v4 68 | with: 69 | path: dist/ 70 | 71 | deploy: 72 | name: Deploy website 73 | 74 | needs: build 75 | 76 | if: ${{ github.event_name == 'push' || inputs.deploy }} 77 | 78 | runs-on: ubuntu-latest 79 | 80 | concurrency: 81 | group: github-pages 82 | cancel-in-progress: true 83 | 84 | environment: 85 | name: github-pages 86 | url: ${{ steps.deploy.outputs.page_url }} 87 | 88 | permissions: 89 | id-token: write 90 | pages: write 91 | 92 | steps: 93 | - name: Deploy to GitHub Pages 94 | id: deploy 95 | uses: actions/deploy-pages@v4 96 | -------------------------------------------------------------------------------- /modules/home-manager/fcitx5.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | 4 | let 5 | inherit (config.catppuccin) sources; 6 | 7 | cfg = config.catppuccin.fcitx5; 8 | enable = 9 | cfg.enable 10 | && ( 11 | ( 12 | config.i18n.inputMethod ? enable 13 | && config.i18n.inputMethod.enable 14 | && config.i18n.inputMethod.type == "fcitx5" 15 | ) 16 | || config.i18n.inputMethod.enabled == "fcitx5" 17 | ); 18 | 19 | package = sources.fcitx5.override { 20 | inherit (cfg) enableRounded; 21 | }; 22 | in 23 | 24 | { 25 | options.catppuccin.fcitx5 = 26 | catppuccinLib.mkCatppuccinOption { 27 | name = "Fcitx5"; 28 | accentSupport = true; 29 | } 30 | // { 31 | apply = lib.mkOption { 32 | type = lib.types.bool; 33 | default = true; 34 | description = '' 35 | Applies the theme by overwriting `$XDG_CONFIG_HOME/fcitx5/conf/classicui.conf`. 36 | If this is disabled, you must manually set the theme (e.g. by using `fcitx5-configtool`). 37 | ''; 38 | }; 39 | 40 | enableRounded = lib.mkEnableOption "rounded corners for the Fcitx5 theme"; 41 | }; 42 | 43 | imports = 44 | (catppuccinLib.mkRenamedCatppuccinOptions { 45 | from = [ 46 | "i18n" 47 | "inputMethod" 48 | "fcitx5" 49 | "catppuccin" 50 | ]; 51 | to = "fcitx5"; 52 | accentSupport = true; 53 | }) 54 | ++ [ 55 | (lib.mkRenamedOptionModule 56 | [ 57 | "i18n" 58 | "inputMethod" 59 | "fcitx5" 60 | "catppuccin" 61 | "apply" 62 | ] 63 | [ 64 | "catppuccin" 65 | "fcitx5" 66 | "apply" 67 | ] 68 | ) 69 | ]; 70 | 71 | config = lib.mkIf enable { 72 | xdg.dataFile = { 73 | "fcitx5/themes/catppuccin-${cfg.flavor}-${cfg.accent}" = { 74 | source = "${package}/share/fcitx5/themes/catppuccin-${cfg.flavor}-${cfg.accent}"; 75 | recursive = true; 76 | }; 77 | }; 78 | 79 | xdg.configFile = { 80 | "fcitx5/conf/classicui.conf" = lib.mkIf cfg.apply { 81 | text = lib.generators.toINIWithGlobalSection { } { 82 | globalSection.Theme = "catppuccin-${cfg.flavor}-${cfg.accent}"; 83 | }; 84 | }; 85 | }; 86 | }; 87 | } 88 | -------------------------------------------------------------------------------- /default.nix: -------------------------------------------------------------------------------- 1 | { 2 | pkgs ? import { 3 | inherit system; 4 | config = { }; 5 | overlays = [ ]; 6 | }, 7 | lib ? pkgs.lib, 8 | system ? builtins.currentSystem, 9 | }: 10 | 11 | let 12 | catppuccinPackages = 13 | let 14 | generated = lib.foldlAttrs ( 15 | acc: port: 16 | { 17 | rev, 18 | hash, 19 | lastModified, 20 | }: 21 | lib.recursiveUpdate acc { 22 | # Save our sources for each port 23 | sources.${port} = catppuccinPackages.fetchCatppuccinPort { inherit port rev hash; }; 24 | 25 | # And create a default package for them 26 | "${port}" = catppuccinPackages.buildCatppuccinPort { inherit port lastModified; }; 27 | } 28 | ) { } (lib.importJSON ./pkgs/sources.json); 29 | 30 | collected = lib.packagesFromDirectoryRecursive { 31 | callPackage = lib.callPackageWith (pkgs // catppuccinPackages); 32 | directory = ./pkgs; 33 | }; 34 | in 35 | generated 36 | // collected 37 | /* 38 | TODO(@getchoo): Remove this with 25.05!!! 39 | 40 | Pin foot to an older version in Nixpkgs < 25.11. See: 41 | - https://github.com/catppuccin/nix/issues/636 42 | - https://github.com/catppuccin/nix/pull/622 43 | */ 44 | // lib.optionalAttrs (!(lib.versionAtLeast lib.version "25.11pre")) { 45 | foot = generated.foot.overrideAttrs (oldAttrs: { 46 | src = oldAttrs.src.override { 47 | rev = "962ff1a5b6387bc5419e9788a773a080eea5f1e1"; 48 | hash = "sha256-eVH3BY2fZe0/OjqucM/IZthV8PMsM9XeIijOg8cNE1Y="; 49 | }; 50 | 51 | lastModified = "2024-09-24"; 52 | }); 53 | }; 54 | in 55 | 56 | { 57 | # Filter out derivations not available on/meant for the current system 58 | packages = lib.filterAttrs (lib.const ( 59 | deriv: 60 | let 61 | # Only export packages available on the current system, *unless* they are being cross compiled 62 | availableOnHost = lib.meta.availableOn pkgs.stdenv.hostPlatform deriv; 63 | # `nix flake check` doesn't like broken packages 64 | broken = deriv.meta.broken or false; 65 | isCross = deriv.stdenv.buildPlatform != deriv.stdenv.targetPlatform; 66 | # Make sure we don't remove our functions 67 | isFunction = lib.isFunction deriv; 68 | in 69 | isFunction || (!broken) && availableOnHost || isCross 70 | )) catppuccinPackages; 71 | 72 | shell = import ./shell.nix { inherit pkgs; }; 73 | } 74 | -------------------------------------------------------------------------------- /.github/workflows/update-locks.yml: -------------------------------------------------------------------------------- 1 | name: Update lockfiles 2 | 3 | on: 4 | schedule: 5 | # run every friday 6 | - cron: "0 0 * * 5" 7 | workflow_dispatch: 8 | 9 | jobs: 10 | flake: 11 | name: Update flake.lock 12 | 13 | runs-on: ubuntu-latest 14 | 15 | permissions: 16 | actions: write 17 | contents: write 18 | pull-requests: write 19 | 20 | steps: 21 | - name: Checkout repository 22 | uses: actions/checkout@v6 23 | 24 | - name: Install Nix 25 | uses: cachix/install-nix-action@v31 26 | with: 27 | # NOTE: Required for subflake 28 | install_url: https://releases.nixos.org/nix/nix-2.26.0/install 29 | 30 | - name: Update Flakes 31 | run: | 32 | nix flake update --flake . 33 | nix flake update --flake ./dev 34 | 35 | - name: Create pull request 36 | id: create-pull-request 37 | uses: peter-evans/create-pull-request@v7 38 | with: 39 | token: ${{ github.token }} 40 | commit-message: "chore: update flakes" 41 | title: "chore: update flakes" 42 | signoff: true 43 | sign-commits: true 44 | branch: "update-flake-lock" 45 | 46 | - name: Run CI 47 | env: 48 | GH_TOKEN: ${{ github.token }} 49 | run: | 50 | gh workflow run ci.yml \ 51 | --ref ${{ steps.create-pull-request.outputs.pull-request-branch }} 52 | 53 | ports: 54 | name: Update port sources 55 | 56 | runs-on: ubuntu-latest 57 | 58 | permissions: 59 | actions: write 60 | contents: write 61 | pull-requests: write 62 | 63 | steps: 64 | - name: Checkout repository 65 | uses: actions/checkout@v6 66 | 67 | - name: Install Nix 68 | uses: cachix/install-nix-action@v31 69 | with: 70 | # NOTE: Required for paws 71 | nix_path: nixpkgs=channel:nixos-unstable 72 | 73 | - name: Update ports 74 | run: ./pkgs/paws.py 75 | 76 | - name: Create pull request 77 | id: create-pull-request 78 | uses: peter-evans/create-pull-request@v7 79 | with: 80 | token: ${{ github.token }} 81 | commit-message: "chore: update port sources" 82 | title: "chore: update port sources" 83 | signoff: true 84 | sign-commits: true 85 | branch: "update-ports" 86 | 87 | - name: Run CI 88 | env: 89 | GH_TOKEN: ${{ github.token }} 90 | run: | 91 | gh workflow run ci.yml \ 92 | --ref ${{ steps.create-pull-request.outputs.pull-request-branch }} 93 | -------------------------------------------------------------------------------- /modules/nixos/gitea.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { 3 | lib, 4 | config, 5 | ... 6 | }: 7 | let 8 | inherit (config.catppuccin) sources; 9 | 10 | valuesFromEnum = 11 | enum: if lib.isList enum.functor.payload then enum.functor.payload else enum.functor.payload.values; 12 | 13 | supportedForges = [ 14 | "gitea" 15 | "forgejo" 16 | ]; 17 | 18 | builtinThemes = { 19 | gitea = [ 20 | "auto" 21 | "gitea" 22 | "arc-greeen" 23 | ]; 24 | 25 | forgejo = [ 26 | "forgejo-auto" 27 | "forgejo-light" 28 | "forgejo-dark" 29 | "gitea-auto" 30 | "gitea-light" 31 | "gitea-dark" 32 | "forgejo-auto-deuteranopia-protanopia" 33 | "forgejo-light-deuteranopia-protanopia" 34 | "forgejo-dark-deuteranopia-protanopia" 35 | "forgejo-auto-tritanopia" 36 | "forgejo-light-tritanopia" 37 | "forgejo-dark-tritanopia" 38 | ]; 39 | }; 40 | in 41 | { 42 | options.catppuccin = lib.genAttrs supportedForges ( 43 | name: 44 | catppuccinLib.mkCatppuccinOption { 45 | inherit name; 46 | accentSupport = true; 47 | } 48 | ); 49 | 50 | config = lib.mkMerge ( 51 | map ( 52 | forge: 53 | let 54 | cfg = config.catppuccin.${forge}; 55 | 56 | inherit (config.services.${forge}) customDir; 57 | hasAssetsDir = lib.versionAtLeast config.services.${forge}.package.version "1.21.0"; 58 | themeDir = if hasAssetsDir then "${customDir}/public/assets/css" else "${customDir}/public/css"; 59 | in 60 | lib.mkIf (cfg.enable && config.services.${forge}.enable) { 61 | systemd.tmpfiles.settings."10-catppuccin-${forge}-theme" = { 62 | ${themeDir}."C+" = { 63 | argument = toString sources.gitea; 64 | }; 65 | 66 | "${customDir}/public".d = { 67 | inherit (config.services.${forge}) user group; 68 | }; 69 | 70 | "${customDir}/public/assets".d = lib.attrsets.optionalAttrs (hasAssetsDir) { 71 | inherit (config.services.${forge}) user group; 72 | }; 73 | }; 74 | 75 | services.${forge}.settings.ui = { 76 | DEFAULT_THEME = "catppuccin-${cfg.flavor}-${cfg.accent}"; 77 | THEMES = lib.concatStringsSep "," ( 78 | builtinThemes.${forge} 79 | ++ (lib.mapCartesianProduct ({ flavor, accent }: "catppuccin-${flavor}-${accent}") ( 80 | lib.mapAttrs (lib.const valuesFromEnum) { 81 | inherit (catppuccinLib.types) accent flavor; 82 | } 83 | )) 84 | ); 85 | }; 86 | } 87 | ) supportedForges 88 | ); 89 | } 90 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 |

2 | Logo
3 | 4 | Catppuccin for Nix 5 | 6 |

7 | 8 |

9 | 10 | 11 | 12 |

13 | 14 |

15 | 16 |

17 | 18 | ## Previews 19 | 20 |
21 | 🌻 Latte 22 | 23 |
24 |
25 | 🪴 Frappé 26 | 27 |
28 |
29 | 🌺 Macchiato 30 | 31 |
32 |
33 | 🌿 Mocha 34 | 35 |
36 | 37 | ## Usage 38 | 39 | This port is documented on our website, [nix.catppuccin.com](https://nix.catppuccin.com). There you can find: 40 | 41 | - Our [Getting Started](https://nix.catppuccin.com/getting-started/) guide 42 | - [Release changelogs](https://nix.catppuccin.com/changelog/) 43 | - [Frequently Asked Questions](https://nix.catppuccin.com/faq/) 44 | - [Options List](https://nix.catppuccin.com/options/main/nixos/catppuccin/) 45 | 46 | ## 💝 Thanks to 47 | 48 | - [Stonks3141](https://github.com/Stonks3141) 49 | - [getchoo](https://github.com/getchoo) 50 | 51 |   52 | 53 |

54 | 55 |

56 | 57 |

58 | Copyright © 2023-present Catppuccin Org 59 |

60 | 61 |

62 | 63 |

64 | -------------------------------------------------------------------------------- /pkgs/paws.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env nix-shell 2 | #! nix-shell --pure -i python3 -p python3 cacert nix 3 | import asyncio 4 | import argparse 5 | import json 6 | import subprocess 7 | from multiprocessing import cpu_count 8 | from datetime import datetime, timezone 9 | from pathlib import Path 10 | 11 | # Directory of the current script 12 | ROOT = Path(__file__).resolve().parent 13 | 14 | # Nix command to fetch a port with 15 | FETCH_ARGS = [ 16 | "--extra-experimental-features", 17 | "nix-command flakes", 18 | "flake", 19 | "prefetch", 20 | "--json", 21 | ] 22 | 23 | SOURCES_FILE = ROOT / "sources.json" 24 | 25 | 26 | fetch_port_sem = asyncio.Semaphore(cpu_count()) 27 | 28 | async def fetch_port(port: str) -> dict: 29 | """Fetch a Catppuccin port""" 30 | 31 | async with fetch_port_sem: 32 | repository = f"github:catppuccin/{port}" 33 | print(f"🔃 Fetching {repository}") 34 | 35 | command = FETCH_ARGS + [repository] 36 | proc = await asyncio.create_subprocess_exec("nix", *command, stdout=asyncio.subprocess.PIPE, stderr=asyncio.subprocess.DEVNULL) 37 | stdout, _ = await proc.communicate() 38 | 39 | if proc.returncode != 0: 40 | raise Exception(f"Failed to fetch {repository}") 41 | 42 | return json.loads(stdout) 43 | 44 | 45 | def update_file_with(old_sources: dict, new_sources: dict): 46 | """Update file with new sources only when needed""" 47 | if new_sources != old_sources: 48 | with open(SOURCES_FILE, "w") as f: 49 | json.dump(new_sources, f, indent=2, sort_keys=True) 50 | else: 51 | print("⚠ No updates made") 52 | 53 | 54 | async def handle_port(sources: dict, port: str, remove=False): 55 | """Handle updating a port in the given sources""" 56 | if remove: 57 | sources.pop(port, None) 58 | print(f"💣 Removed {port}") 59 | else: 60 | data = await fetch_port(port) 61 | locked = data["locked"] 62 | last_modified = datetime.fromtimestamp(int(locked["lastModified"]), tz = timezone.utc).strftime('%Y-%m-%d') 63 | sources[port] = {"rev": locked["rev"], "hash": data["hash"], "lastModified": last_modified} 64 | 65 | 66 | async def main(): 67 | cur_sources = dict() 68 | if SOURCES_FILE.exists(): 69 | with open(SOURCES_FILE, "r") as f: 70 | cur_sources = json.load(f) 71 | 72 | parser = argparse.ArgumentParser(prog="paws") 73 | parser.add_argument("ports", default=cur_sources.keys(), nargs="*") 74 | parser.add_argument("-r", "--remove", action="store_true") 75 | args = parser.parse_args() 76 | 77 | assert ( 78 | not args.remove or len(args.ports) > 0 79 | ), "Ports must be provided when passing --remove" 80 | 81 | new_sources = cur_sources.copy() 82 | await asyncio.gather( 83 | *[handle_port(new_sources, port, remove=args.remove) for port in args.ports] 84 | ) 85 | 86 | update_file_with(cur_sources, new_sources) 87 | 88 | print("✅ Done!") 89 | 90 | 91 | asyncio.run(main()) 92 | -------------------------------------------------------------------------------- /dev/flake.lock: -------------------------------------------------------------------------------- 1 | { 2 | "nodes": { 3 | "catppuccin": { 4 | "inputs": { 5 | "nixpkgs": "nixpkgs" 6 | }, 7 | "locked": { 8 | "path": "../.", 9 | "type": "path" 10 | }, 11 | "original": { 12 | "path": "../.", 13 | "type": "path" 14 | }, 15 | "parent": [] 16 | }, 17 | "flake-utils": { 18 | "inputs": { 19 | "systems": "systems" 20 | }, 21 | "locked": { 22 | "lastModified": 1731533236, 23 | "narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=", 24 | "owner": "numtide", 25 | "repo": "flake-utils", 26 | "rev": "11707dc2f618dd54ca8739b309ec4fc024de578b", 27 | "type": "github" 28 | }, 29 | "original": { 30 | "owner": "numtide", 31 | "repo": "flake-utils", 32 | "type": "github" 33 | } 34 | }, 35 | "home-manager": { 36 | "inputs": { 37 | "nixpkgs": [ 38 | "nixpkgs" 39 | ] 40 | }, 41 | "locked": { 42 | "lastModified": 1764194569, 43 | "narHash": "sha256-iUM9ktarEzThkayyZrzQ7oycPshAY2XRQqVKz0xX/L0=", 44 | "owner": "nix-community", 45 | "repo": "home-manager", 46 | "rev": "9651819d75f6c7ffaf8a9227490ac704f29659f0", 47 | "type": "github" 48 | }, 49 | "original": { 50 | "owner": "nix-community", 51 | "repo": "home-manager", 52 | "type": "github" 53 | } 54 | }, 55 | "nixpkgs": { 56 | "locked": { 57 | "lastModified": 1763966396, 58 | "narHash": "sha256-6eeL1YPcY1MV3DDStIDIdy/zZCDKgHdkCmsrLJFiZf0=", 59 | "owner": "NixOS", 60 | "repo": "nixpkgs", 61 | "rev": "5ae3b07d8d6527c42f17c876e404993199144b6a", 62 | "type": "github" 63 | }, 64 | "original": { 65 | "owner": "NixOS", 66 | "ref": "nixos-unstable", 67 | "repo": "nixpkgs", 68 | "type": "github" 69 | } 70 | }, 71 | "root": { 72 | "inputs": { 73 | "catppuccin": "catppuccin", 74 | "flake-utils": "flake-utils", 75 | "home-manager": "home-manager", 76 | "nixpkgs": [ 77 | "catppuccin", 78 | "nixpkgs" 79 | ] 80 | } 81 | }, 82 | "systems": { 83 | "locked": { 84 | "lastModified": 1681028828, 85 | "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", 86 | "owner": "nix-systems", 87 | "repo": "default", 88 | "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", 89 | "type": "github" 90 | }, 91 | "original": { 92 | "owner": "nix-systems", 93 | "repo": "default", 94 | "type": "github" 95 | } 96 | } 97 | }, 98 | "root": "root", 99 | "version": 7 100 | } 101 | -------------------------------------------------------------------------------- /modules/home-manager/zsh-syntax-highlighting.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { 3 | options, 4 | config, 5 | lib, 6 | ... 7 | }: 8 | 9 | let 10 | inherit (config.catppuccin) sources; 11 | 12 | cfg = config.catppuccin.zsh-syntax-highlighting; 13 | oldCfg = config.programs.zsh.syntaxHighlighting.catppuccin; 14 | 15 | isSubmoduleOptionDefined = value: (builtins.tryEval value).success; 16 | in 17 | 18 | { 19 | options = { 20 | catppuccin.zsh-syntax-highlighting = catppuccinLib.mkCatppuccinOption { 21 | name = "Zsh Syntax Highlighting"; 22 | }; 23 | 24 | # `mkRenamedOptionModule` can't rename submodule options to top-level ones 25 | # Enter this nonsense 26 | # TODO: Abstract this 27 | 28 | # Extend the base submodule with our own options 29 | programs.zsh.syntaxHighlighting = { 30 | # Create options manually as `mkRenamedOptionModule` would 31 | catppuccin = { 32 | # But don't include the `trace` to each option since we do need to 33 | # check them with `isSubmoduleOptionDefined` 34 | enable = lib.mkOption { 35 | type = lib.types.bool; 36 | description = "Alias of `catppuccin.zsh-syntax-highlighting.enable`"; 37 | visible = false; 38 | }; 39 | 40 | flavor = lib.mkOption { 41 | type = catppuccinLib.types.flavor; 42 | description = "Alias of `catppuccin.zsh-syntax-highlighting.flavor`"; 43 | visible = false; 44 | }; 45 | }; 46 | }; 47 | }; 48 | 49 | config = lib.mkMerge [ 50 | (lib.mkIf (isSubmoduleOptionDefined oldCfg.enable) { 51 | # Place the warning, also like `mkRenamedOptionModule` normally would 52 | warnings = [ 53 | "The option `programs.zsh.syntaxHighlighting.catppuccin.enable` has been renamed to `catppuccin.zsh-syntax-highlighting.enable`." 54 | ]; 55 | 56 | # Actually alias the option 57 | catppuccin.zsh-syntax-highlighting.enable = oldCfg.enable; 58 | }) 59 | 60 | # Do it again for the flavor 61 | (lib.mkIf (isSubmoduleOptionDefined oldCfg.flavor) { 62 | warnings = [ 63 | "The option `programs.zsh.syntaxHighlighting.catppuccin.flavor` has been renamed to `catppuccin.zsh-syntax-highlighting.flavor`." 64 | ]; 65 | 66 | catppuccin.zsh-syntax-highlighting.flavor = oldCfg.flavor; 67 | }) 68 | 69 | # And this is our actual module 70 | (lib.mkIf cfg.enable { 71 | programs.zsh = 72 | let 73 | key = if options.programs.zsh ? initContent then "initContent" else "initExtra"; 74 | in 75 | { 76 | # NOTE: Backwards compatible mkOrder priority working with stable/unstable HM. 77 | "${key}" = lib.mkOrder (if key == "initContent" then 950 else 500) '' 78 | source '${sources.zsh-syntax-highlighting}/catppuccin_${cfg.flavor}-zsh-syntax-highlighting.zsh' 79 | ''; 80 | }; 81 | }) 82 | ]; 83 | } 84 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | ## Nix 2 | result 3 | result-* 4 | repl-result-* 5 | gcroot/ 6 | 7 | ## Astro 8 | 9 | .astro/ 10 | 11 | ## Git 12 | 13 | .worktree/ 14 | 15 | ## NodeJS 16 | 17 | # Logs 18 | logs 19 | *.log 20 | npm-debug.log* 21 | yarn-debug.log* 22 | yarn-error.log* 23 | lerna-debug.log* 24 | 25 | # Diagnostic reports (https://nodejs.org/api/report.html) 26 | report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json 27 | 28 | # Runtime data 29 | pids 30 | *.pid 31 | *.seed 32 | *.pid.lock 33 | 34 | # Directory for instrumented libs generated by jscoverage/JSCover 35 | lib-cov 36 | 37 | # Coverage directory used by tools like istanbul 38 | coverage 39 | *.lcov 40 | 41 | # nyc test coverage 42 | .nyc_output 43 | 44 | # Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files) 45 | .grunt 46 | 47 | # Bower dependency directory (https://bower.io/) 48 | bower_components 49 | 50 | # node-waf configuration 51 | .lock-wscript 52 | 53 | # Compiled binary addons (https://nodejs.org/api/addons.html) 54 | build/Release 55 | 56 | # Dependency directories 57 | node_modules/ 58 | jspm_packages/ 59 | 60 | # Snowpack dependency directory (https://snowpack.dev/) 61 | web_modules/ 62 | 63 | # TypeScript cache 64 | *.tsbuildinfo 65 | 66 | # Optional npm cache directory 67 | .npm 68 | 69 | # Optional eslint cache 70 | .eslintcache 71 | 72 | # Optional stylelint cache 73 | .stylelintcache 74 | 75 | # Optional REPL history 76 | .node_repl_history 77 | 78 | # Output of 'npm pack' 79 | *.tgz 80 | 81 | # Yarn Integrity file 82 | .yarn-integrity 83 | 84 | # dotenv environment variable files 85 | .env 86 | .env.* 87 | !.env.example 88 | 89 | # parcel-bundler cache (https://parceljs.org/) 90 | .cache 91 | .parcel-cache 92 | 93 | # Next.js build output 94 | .next 95 | out 96 | 97 | # Nuxt.js build / generate output 98 | .nuxt 99 | dist 100 | 101 | # Gatsby files 102 | .cache/ 103 | # Comment in the public line in if your project uses Gatsby and not Next.js 104 | # https://nextjs.org/blog/next-9-1#public-directory-support 105 | # public 106 | 107 | # vuepress build output 108 | .vuepress/dist 109 | 110 | # vuepress v2.x temp and cache directory 111 | .temp 112 | .cache 113 | 114 | # Sveltekit cache directory 115 | .svelte-kit/ 116 | 117 | # vitepress build output 118 | **/.vitepress/dist 119 | 120 | # vitepress cache directory 121 | **/.vitepress/cache 122 | 123 | # Docusaurus cache and generated files 124 | .docusaurus 125 | 126 | # Serverless directories 127 | .serverless/ 128 | 129 | # FuseBox cache 130 | .fusebox/ 131 | 132 | # DynamoDB Local files 133 | .dynamodb/ 134 | 135 | # Firebase cache directory 136 | .firebase/ 137 | 138 | # TernJS port file 139 | .tern-port 140 | 141 | # Stores VSCode versions used for testing VSCode extensions 142 | .vscode-test 143 | 144 | # yarn v3 145 | .pnp.* 146 | .yarn/* 147 | !.yarn/patches 148 | !.yarn/plugins 149 | !.yarn/releases 150 | !.yarn/sdks 151 | !.yarn/versions 152 | 153 | # Vite logs files 154 | vite.config.js.timestamp-* 155 | vite.config.ts.timestamp-* 156 | -------------------------------------------------------------------------------- /cliff.toml: -------------------------------------------------------------------------------- 1 | # git-cliff ~ configuration file 2 | # https://git-cliff.org/docs/configuration 3 | # 4 | # To bump the changelog: 5 | # 6 | # ```console 7 | # $ TAG="x.y.z" 8 | # $ TAG=v"$TAG" 9 | # $ git-cliff --github-token (gh auth token) --prepend CHANGELOG.md --tag "$TAG" --unreleased 10 | # ``` 11 | 12 | [changelog] 13 | header = """ 14 | # Changelog\n 15 | """ 16 | 17 | body = """ 18 | {% if version -%} 19 | ## [{{ version | trim_start_matches(pat="v") }}](https://github.com/catppuccin/nix/releases/tag/{{ version }}) - {{ timestamp | date(format="%Y-%m-%d") }} 20 | {% else -%} 21 | ## [Unreleased] 22 | {% endif -%} 23 | 24 | {% for group, commits in commits | group_by(attribute="group") %} 25 | ### {{ group | striptags | trim | upper_first }} 26 | 27 | {% for commit in commits | filter(attribute="scope") | sort(attribute="scope") -%} 28 | - **{{ commit.scope }}**: {{ commit.message | trim }}\ 29 | {%- if commit.remote.username %} by @{{ commit.remote.username }}{% endif %} 30 | {% endfor -%} 31 | 32 | {% for commit in commits -%} 33 | {% if commit.scope -%} 34 | {% else -%} 35 | - {{ commit.message | trim }}\ 36 | {% if commit.remote.username %} by @{{ commit.remote.username }}{% endif %} 37 | {% endif -%} 38 | {% endfor -%} 39 | {% endfor -%} 40 | 41 | {% if github.contributors | filter(attribute="is_first_time", value=true) | length != 0 %} 42 | ### New Contributors 43 | 44 | {% endif -%} 45 | 46 | {% for contributor in github.contributors | filter(attribute="username") | filter(attribute="is_first_time", value=true) | sort(attribute="username") -%} 47 | * @{{ contributor.username }} made their first contribution\ 48 | {% if contributor.pr_number %} in #{{ contributor.pr_number }}{% endif %} 49 | {% endfor %}\n 50 | """ 51 | 52 | footer = """ 53 | 54 | """ 55 | 56 | trim = true 57 | 58 | postprocessors = [ 59 | # Issues/PR 60 | { pattern = "#([0-9]+)", replace = "[#${1}](https://github.com/catppuccin/nix/issues/${1})" }, 61 | # Commits 62 | { pattern = "([a-f0-9]{7})", replace = "[${1}](https://github.com/catppuccin/nix/commit/${1})" }, 63 | # GitHub Users 64 | { pattern = " @([a-zA-Z0-9-_]+)", replace = " [@${1}](https://github.com/${1})" } 65 | ] 66 | 67 | [git] 68 | commit_preprocessors = [ 69 | # Remove issue numbers 70 | { pattern = '\((\w+\s)?#([0-9]+)\)', replace = "" }, 71 | ] 72 | 73 | commit_parsers = [ 74 | # This commit message isn't properly escaped 75 | { sha = "aa3a9816e9d6bc361ab1156f1e7a850fc0b5f4f8", skip = true }, 76 | 77 | # Ignore bot PRs 78 | { field = "author.name", pattern = "\\[bot\\]", skip = true }, 79 | 80 | # Ignore some commits not matched by the above 81 | { message = "^docs: update docs for( ([a-f0-9]{7}))?$", skip = true }, 82 | { message = "^style: format ([a-f0-9]{7})?$", skip = true }, 83 | 84 | # Regular matches 85 | { message = "^(.*)!:", group = "🚨 Breaking Changes" }, 86 | { message = "^feat", group = "🚀 Features" }, 87 | { message = "^fix", group = "🐛 Bug Fixes" }, 88 | { message = "^revert", group = " ⏪ Reverted"}, 89 | { message = "^docs", group = "📚 Documentation" }, 90 | ] 91 | 92 | filter_commits = true 93 | 94 | [remote.github] 95 | owner = "catppuccin" 96 | repo = "nix" 97 | -------------------------------------------------------------------------------- /modules/home-manager/gtk.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { 3 | config, 4 | lib, 5 | pkgs, 6 | ... 7 | }: 8 | 9 | let 10 | inherit (lib) 11 | concatStringsSep 12 | mkRenamedOptionModule 13 | mkRemovedOptionModule 14 | toList 15 | ; 16 | 17 | cfg = config.catppuccin.gtk; 18 | 19 | namespaceRenameModules = 20 | catppuccinLib.mkRenamedCatppuccinOptions { 21 | from = [ 22 | "gtk" 23 | "catppuccin" 24 | ]; 25 | to = "gtk"; 26 | accentSupport = true; 27 | } 28 | ++ catppuccinLib.mkRenamedCatppuccinOptions { 29 | from = [ 30 | "gtk" 31 | "catppuccin" 32 | "cursor" 33 | ]; 34 | to = "cursors"; 35 | accentSupport = true; 36 | } 37 | ++ [ 38 | (mkRenamedOptionModule 39 | [ 40 | "gtk" 41 | "catppuccin" 42 | "size" 43 | ] 44 | [ 45 | "catppuccin" 46 | "gtk" 47 | "size" 48 | ] 49 | ) 50 | 51 | (mkRenamedOptionModule 52 | [ 53 | "gtk" 54 | "catppuccin" 55 | "tweaks" 56 | ] 57 | [ 58 | "catppuccin" 59 | "gtk" 60 | "tweaks" 61 | ] 62 | ) 63 | 64 | (mkRenamedOptionModule 65 | [ 66 | "gtk" 67 | "catppuccin" 68 | "gnomeShellTheme" 69 | ] 70 | [ 71 | "catppuccin" 72 | "gtk" 73 | "gnomeShellTheme" 74 | ] 75 | ) 76 | 77 | (mkRenamedOptionModule 78 | [ 79 | "gtk" 80 | "catppuccin" 81 | "icon" 82 | ] 83 | [ 84 | "catppuccin" 85 | "gtk" 86 | "icon" 87 | ] 88 | ) 89 | ]; 90 | 91 | # Relative to `catppuccin.gtk` 92 | removedOptions = [ 93 | "enable" 94 | "flavor" 95 | "accent" 96 | 97 | "gnomeShellTheme" 98 | "size" 99 | "tweaks" 100 | ]; 101 | 102 | removedOptionModules = map ( 103 | optionPath: 104 | 105 | let 106 | attrPath = [ 107 | "catppuccin" 108 | "gtk" 109 | ] 110 | ++ toList optionPath; 111 | moduleName = concatStringsSep "." attrPath; 112 | in 113 | 114 | mkRemovedOptionModule attrPath '' 115 | `${moduleName}` was removed from catppuccin/nix, as the upstream port has been archived and began experiencing breakages. 116 | 117 | Please see https://github.com/catppuccin/gtk/issues/262 118 | '' 119 | ) removedOptions; 120 | in 121 | 122 | { 123 | imports = namespaceRenameModules ++ removedOptionModules; 124 | 125 | options.catppuccin.gtk = { 126 | icon = catppuccinLib.mkCatppuccinOption { 127 | name = "GTK modified Papirus icon theme"; 128 | 129 | accentSupport = true; 130 | }; 131 | }; 132 | 133 | config = lib.mkIf cfg.icon.enable { 134 | gtk.iconTheme = 135 | let 136 | # use the light icon theme for latte 137 | polarity = if cfg.icon.flavor == "latte" then "Light" else "Dark"; 138 | in 139 | { 140 | name = "Papirus-${polarity}"; 141 | package = pkgs.catppuccin-papirus-folders.override { inherit (cfg.icon) accent flavor; }; 142 | }; 143 | }; 144 | } 145 | -------------------------------------------------------------------------------- /docs/content/docs/Getting Started/stable.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Stable Nix 3 | description: Start using Catppuccin with Flakes, NixOS, and home-manager 4 | --- 5 | 6 | import { Tabs, TabItem } from "@astrojs/starlight/components"; 7 | 8 | When using stable Nix, we have a couple options for installing `catppuccin/nix`: 9 | 10 | ## With `npins` 11 | 12 | [`npins`](https://github.com/andir/npins) provides a way to easily ["pin"](https://nix.dev/tutorials/first-steps/towards-reproducibility-pinning-nixpkgs) and update external dependencies for your configurations. 13 | 14 | Assuming you have followed [their getting started guide](https://github.com/andir/npins#getting-started), you can run the following: 15 | 16 | 17 | 18 | 19 | 20 | ```sh 21 | npins add --name catppuccin github catppuccin nix 22 | ``` 23 | 24 | 25 | 26 | 27 | 28 | ```sh 29 | npins add --name catppuccin --branch release-25.05 github catppuccin nix 30 | ``` 31 | 32 | 33 | 34 | 35 | 36 | And in your system configuration: 37 | 38 | ```nix 39 | let 40 | sources = import ./npins; 41 | in 42 | { 43 | imports = [ 44 | (sources.catppuccin + "/modules/nixos") 45 | ]; 46 | 47 | # if you use home-manager 48 | home-manager.users.pepperjack = { 49 | imports = [ 50 | (sources.catppuccin + "/modules/home-manager") 51 | ]; 52 | }; 53 | } 54 | ``` 55 | 56 | or if you use a [standalone installation](https://nix-community.github.io/home-manager/index.html#sec-install-standalone) of `home-manager` 57 | 58 | ```nix 59 | let 60 | sources = import ./npins.nix; 61 | in 62 | { 63 | imports = [ 64 | (sources.catppuccin + "/modules/home-manager") 65 | ]; 66 | 67 | home.username = "pepperjack"; 68 | programs.home-manager.enable = true; 69 | } 70 | 71 | ``` 72 | 73 | ## With channels 74 | 75 | [Nix channels](https://nixos.org/manual/nix/stable/command-ref/nix-channel.html) provide a way for you to easily download, update, and use our modules -- though at the cost of reproducible across machines. 76 | 77 | To add `catppuccin/nix` as a channel, you can run the following: 78 | 79 | 80 | 81 | 82 | 83 | ```sh 84 | sudo nix-channel --add https://github.com/catppuccin/nix/archive/main.tar.gz catppuccin 85 | sudo nix-channel --update 86 | ``` 87 | 88 | 89 | 90 | 91 | 92 | ```sh 93 | sudo nix-channel --add https://github.com/catppuccin/nix/archive/release-25.05.tar.gz catppuccin 94 | sudo nix-channel --update 95 | ``` 96 | 97 | 98 | 99 | 100 | 101 | And in your system configuration: 102 | 103 | ```nix 104 | { 105 | imports = [ 106 | 107 | ]; 108 | 109 | # if you use home-manager 110 | home-manager.users.pepperjack = { 111 | imports = [ 112 | 113 | ]; 114 | }; 115 | } 116 | ``` 117 | 118 | or if you use a [standalone installation](https://nix-community.github.io/home-manager/index.html#sec-install-standalone) of `home-manager` 119 | 120 | ```nix 121 | { 122 | imports = [ 123 | 124 | ]; 125 | 126 | home.username = "pepperjack"; 127 | programs.home-manager.enable = true; 128 | } 129 | 130 | ``` 131 | -------------------------------------------------------------------------------- /docs/content/docs/Getting Started/flakes.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Flakes 3 | description: Start using Catppuccin with Flakes, NixOS, and home-manager 4 | --- 5 | 6 | import { Tabs, TabItem } from "@astrojs/starlight/components"; 7 | 8 | Flakes are the preferred way to use `catppuccin/nix` and will be the easiest method for most. 9 | 10 | First, we need to add the project to our inputs so we can use it in our configurations: 11 | 12 | 13 | 14 | 15 | 16 | ```nix 17 | { 18 | inputs = { 19 | nixpkgs.url = "nixpkgs/nixos-unstable"; 20 | catppuccin.url = "github:catppuccin/nix"; 21 | }; 22 | } 23 | ``` 24 | 25 | 26 | 27 | 28 | 29 | ```nix 30 | { 31 | inputs = { 32 | nixpkgs.url = "nixpkgs/nixos-25.05"; 33 | catppuccin.url = "github:catppuccin/nix/release-25.05"; 34 | }; 35 | } 36 | ``` 37 | 38 | 39 | 40 | 41 | 42 | After, we can use them in a NixOS configuration like so 43 | 44 | ```nix 45 | { 46 | nixosConfigurations.pepperjacks-pc = { 47 | modules = [ 48 | ./configuration.nix 49 | 50 | catppuccin.nixosModules.catppuccin 51 | # if you use home-manager 52 | home-manager.nixosModules.home-manager 53 | 54 | { 55 | # if you use home-manager 56 | home-manager.users.pepperjack = { 57 | imports = [ 58 | ./home.nix 59 | catppuccin.homeModules.catppuccin 60 | ]; 61 | }; 62 | } 63 | ]; 64 | }; 65 | } 66 | ``` 67 | 68 | or if you use a [standalone installation](https://nix-community.github.io/home-manager/index.xhtml#sec-install-standalone) of `home-manager` 69 | 70 | ```nix 71 | { 72 | homeConfigurations.pepperjack = home-manager.lib.homeManagerConfiguration { 73 | pkgs = nixpkgs.legacyPackages.x86_64-linux; 74 | modules = [ 75 | ./home.nix 76 | catppuccin.homeModules.catppuccin 77 | ]; 78 | }; 79 | } 80 | ``` 81 | 82 | By the end, you should have a flake.nix that looks something like this 83 | 84 | ```nix 85 | { 86 | inputs = { 87 | nixpkgs.url = "nixpkgs/nixos-unstable"; 88 | catppuccin.url = "github:catppuccin/nix"; 89 | home-manager = { 90 | url = "github:nix-community/home-manager"; 91 | inputs.nixpkgs.follows = "nixpkgs"; 92 | }; 93 | }; 94 | 95 | outputs = { nixpkgs, catppuccin, home-manager }: { 96 | # for nixos module home-manager installations 97 | nixosConfigurations.pepperjacksComputer = pkgs.lib.nixosSystem { 98 | modules = [ 99 | ./configuration.nix 100 | 101 | catppuccin.nixosModules.catppuccin 102 | # if you use home-manager 103 | home-manager.nixosModules.home-manager 104 | 105 | { 106 | # if you use home-manager 107 | home-manager.users.pepperjack = { 108 | imports = [ 109 | ./home.nix 110 | catppuccin.homeModules.catppuccin 111 | ]; 112 | }; 113 | } 114 | ]; 115 | }; 116 | 117 | # for standalone home-manager installations 118 | homeConfigurations.pepperjack = home-manager.lib.homeManagerConfiguration { 119 | pkgs = nixpkgs.legacyPackages.x86_64-linux; 120 | modules = [ 121 | ./home.nix 122 | catppuccin.homeModules.catppuccin 123 | ]; 124 | }; 125 | }; 126 | } 127 | ``` 128 | -------------------------------------------------------------------------------- /modules/home-manager/vscode.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { 3 | config, 4 | lib, 5 | pkgs, 6 | ... 7 | }: 8 | let 9 | inherit (lib) types; 10 | inherit (config.catppuccin) sources; 11 | cfg = config.catppuccin.vscode; 12 | 13 | settingsFormat = pkgs.formats.json { }; 14 | 15 | renamedOptions = [ 16 | "accent" 17 | "enable" 18 | "flavor" 19 | "settings" 20 | ]; 21 | ctpVscOptionPath = [ 22 | "catppuccin" 23 | "vscode" 24 | ]; 25 | newOptionPath = ctpVscOptionPath ++ [ 26 | "profiles" 27 | "default" 28 | ]; 29 | in 30 | { 31 | # Rename old catppuccin.vscode.* options to catppuccin.vscode.profiles..* 32 | imports = map ( 33 | option: lib.mkRenamedOptionModule (ctpVscOptionPath ++ [ option ]) (newOptionPath ++ [ option ]) 34 | ) renamedOptions; 35 | 36 | options.catppuccin.vscode.profiles = lib.mkOption { 37 | type = types.attrsOf ( 38 | types.submodule ( 39 | { config, ... }: 40 | { 41 | options = 42 | catppuccinLib.mkCatppuccinOption { 43 | name = "vscode"; 44 | accentSupport = true; 45 | } 46 | // { 47 | settings = lib.mkOption { 48 | description = '' 49 | Settings for the extension theme. 50 | 51 | See https://github.com/catppuccin/vscode/blob/8ac8c5e1db78174c98c55ecd9c1bd3a6f2cbbc0b/packages/catppuccin-vsc/src/theme/index.ts#L14-L25 for a full list of options. 52 | ''; 53 | 54 | default = { }; 55 | 56 | type = types.submodule { 57 | freeformType = settingsFormat.type; 58 | 59 | options = { 60 | accent = lib.mkOption { 61 | type = catppuccinLib.types.accent; 62 | default = config.accent; 63 | description = "Catppuccin accent for vscode."; 64 | }; 65 | }; 66 | }; 67 | }; 68 | 69 | icons = catppuccinLib.mkCatppuccinOption { name = "vscode-icons"; }; 70 | }; 71 | } 72 | ) 73 | ); 74 | 75 | # by default we list the `default` profile to enable the theme with just the `.enable` option 76 | default = { 77 | default = { }; 78 | }; 79 | 80 | description = "Catppuccin settings for VSCode profiles."; 81 | }; 82 | 83 | config.programs.vscode.profiles = lib.mapAttrs ( 84 | _: profile: 85 | lib.mkIf profile.enable { 86 | extensions = [ 87 | (sources.vscode.override { catppuccinOptions = profile.settings; }) 88 | ] 89 | ++ lib.optional (profile.icons.enable) sources.vscode-icons; 90 | 91 | userSettings = lib.mkMerge [ 92 | { 93 | "workbench.colorTheme" = "Catppuccin " + (catppuccinLib.mkFlavorName profile.flavor); 94 | "catppuccin.accentColor" = profile.accent; 95 | 96 | # Recommended settings 97 | # https://github.com/catppuccin/vscode?tab=readme-ov-file#vscode-settings 98 | "editor.semanticHighlighting.enabled" = lib.mkDefault true; 99 | "terminal.integrated.minimumContrastRatio" = lib.mkDefault 1; 100 | "window.titleBarStyle" = lib.mkDefault "custom"; 101 | } 102 | 103 | (lib.mkIf (profile.icons.enable) { 104 | "workbench.iconTheme" = "catppuccin-" + profile.icons.flavor; 105 | }) 106 | ]; 107 | } 108 | ) cfg.profiles; 109 | } 110 | -------------------------------------------------------------------------------- /flake.nix: -------------------------------------------------------------------------------- 1 | { 2 | description = "Soothing pastel theme for Nix"; 3 | 4 | inputs = { 5 | nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable"; 6 | }; 7 | 8 | outputs = 9 | { self, nixpkgs }: 10 | 11 | let 12 | inherit (nixpkgs) lib; 13 | 14 | # Systems for public outputs 15 | systems = lib.systems.flakeExposed; 16 | 17 | # Systems for development related outputs 18 | # (that evaluate more exotic packages cleanly, unlike some systems above) 19 | devSystems = [ 20 | "x86_64-linux" 21 | "aarch64-linux" 22 | "x86_64-darwin" 23 | "aarch64-darwin" 24 | ]; 25 | 26 | forAllSystems = lib.genAttrs systems; 27 | forAllDevSystems = lib.genAttrs devSystems; 28 | 29 | mkModule = 30 | { 31 | name ? "catppuccin", 32 | type, 33 | file, 34 | }: 35 | { pkgs, ... }: 36 | { 37 | _file = "${self.outPath}/flake.nix#${type}Modules.${name}"; 38 | 39 | imports = [ file ]; 40 | 41 | catppuccin.sources = lib.mkDefault self.packages.${pkgs.stdenv.hostPlatform.system}; 42 | }; 43 | in 44 | 45 | { 46 | packages = forAllSystems ( 47 | system: 48 | let 49 | pkgs = nixpkgs.legacyPackages.${system}; 50 | catppuccinPackages = (import ./default.nix { inherit pkgs; }).packages; 51 | in 52 | catppuccinPackages 53 | // { 54 | default = catppuccinPackages.whiskers; 55 | } 56 | ); 57 | 58 | devShells = forAllDevSystems ( 59 | system: 60 | 61 | let 62 | pkgs = nixpkgs.legacyPackages.${system}; 63 | in 64 | 65 | lib.genAttrs [ "default" "ci" ] ( 66 | name: 67 | import ./shell.nix { 68 | inherit pkgs; 69 | minimal = name == "ci"; 70 | } 71 | ) 72 | ); 73 | 74 | formatter = forAllDevSystems ( 75 | system: 76 | let 77 | pkgs = nixpkgs.legacyPackages.${system}; 78 | in 79 | pkgs.treefmt.withConfig { 80 | runtimeInputs = with pkgs; [ 81 | keep-sorted 82 | nixfmt-rfc-style 83 | ]; 84 | 85 | settings = { 86 | on-unmatched = "info"; 87 | tree-root-file = "flake.nix"; 88 | 89 | formatter = { 90 | keep-sorted = { 91 | command = "keep-sorted"; 92 | includes = [ "*" ]; 93 | }; 94 | nixfmt = { 95 | command = "nixfmt"; 96 | includes = [ "*.nix" ]; 97 | }; 98 | }; 99 | }; 100 | } 101 | ); 102 | 103 | # TODO: Remove before 2.0 is stable 104 | homeManagerModules = lib.mapAttrs ( 105 | name: 106 | lib.warn "Obsolete Flake attribute `catppuccin.homeManagerModules.${name}' is used. It was renamed to `catppuccin.homeModules.${name}`'." 107 | ) self.homeModules; 108 | 109 | homeModules = { 110 | default = self.homeModules.catppuccin; 111 | catppuccin = mkModule { 112 | type = "homeManager"; 113 | file = ./modules/home-manager; 114 | }; 115 | }; 116 | 117 | nixosModules = { 118 | default = self.nixosModules.catppuccin; 119 | catppuccin = mkModule { 120 | type = "nixos"; 121 | file = ./modules/nixos; 122 | }; 123 | }; 124 | }; 125 | } 126 | -------------------------------------------------------------------------------- /modules/tests/home.nix: -------------------------------------------------------------------------------- 1 | { pkgs, ... }: 2 | 3 | let 4 | inherit (pkgs.stdenv.hostPlatform) isLinux; 5 | in 6 | 7 | { 8 | xdg.enable = true; 9 | 10 | i18n.inputMethod = { 11 | enable = isLinux; 12 | type = "fcitx5"; 13 | }; 14 | 15 | catppuccin.xfce4-terminal.enable = isLinux; 16 | 17 | # this is enabled by default already, but still 18 | # listing explicitly so we know it's tested 19 | catppuccin.glamour.enable = true; 20 | 21 | # For `catppuccin.gtk.icon` 22 | gtk.enable = isLinux; 23 | 24 | programs = { 25 | # keep-sorted start block=yes sticky_comments=yes 26 | aerc.enable = true; 27 | alacritty.enable = true; 28 | anki.enable = true; 29 | bat.enable = true; 30 | bottom.enable = true; 31 | brave.enable = true; 32 | btop.enable = true; 33 | cava.enable = true; 34 | chromium.enable = isLinux; 35 | element-desktop.enable = true; 36 | eza.enable = true; 37 | firefox = { 38 | enable = true; 39 | profiles.pepperjack = { 40 | extensions.force = true; 41 | }; 42 | }; 43 | fish.enable = true; 44 | foot.enable = isLinux; 45 | freetube.enable = isLinux; 46 | fuzzel.enable = isLinux; 47 | fzf.enable = true; 48 | gh-dash.enable = true; 49 | ghostty.enable = isLinux; 50 | git = { 51 | enable = true; 52 | delta.enable = true; 53 | }; 54 | gitui.enable = true; 55 | halloy.enable = true; 56 | helix.enable = true; 57 | hyprlock.enable = isLinux; 58 | imv.enable = isLinux; 59 | k9s.enable = true; 60 | kitty.enable = true; 61 | lazygit.enable = true; 62 | lsd.enable = true; 63 | mangohud.enable = isLinux; 64 | micro.enable = true; 65 | mpv.enable = true; 66 | neovim.enable = true; 67 | newsboat.enable = true; 68 | obs-studio.enable = isLinux; 69 | qutebrowser.enable = false; # broken package due to python3.13-lxml-html-clean-0.4.2 70 | rio.enable = true; 71 | rofi.enable = isLinux; 72 | sioyek.enable = true; 73 | skim.enable = true; 74 | spotify-player.enable = true; 75 | starship.enable = true; 76 | swaylock.enable = isLinux; 77 | television.enable = true; 78 | thunderbird = { 79 | enable = isLinux; 80 | profiles.catppuccin-mocha-mauve.isDefault = true; 81 | }; 82 | tmux.enable = true; 83 | tofi.enable = isLinux; 84 | vesktop.enable = true; 85 | vicinae.enable = isLinux; 86 | vivid.enable = true; 87 | vscode = { 88 | enable = true; 89 | package = pkgs.vscodium; 90 | }; 91 | waybar.enable = isLinux; 92 | wezterm.enable = true; 93 | wlogout.enable = isLinux; 94 | yazi.enable = true; 95 | zathura.enable = true; 96 | zed-editor.enable = true; 97 | zellij.enable = true; 98 | zsh = { 99 | enable = true; 100 | syntaxHighlighting.enable = true; 101 | }; 102 | # keep-sorted end 103 | }; 104 | 105 | qt = { 106 | enable = isLinux; 107 | platformTheme.name = "kvantum"; 108 | style.name = "kvantum"; 109 | }; 110 | 111 | services = { 112 | # keep-sorted start block=yes 113 | dunst.enable = isLinux; 114 | mako.enable = isLinux; 115 | polybar = { 116 | enable = isLinux; 117 | script = '' 118 | polybar top & 119 | ''; 120 | }; 121 | swaync.enable = isLinux; 122 | # keep-sorted end 123 | }; 124 | 125 | wayland.windowManager = { 126 | # keep-sorted start 127 | hyprland.enable = isLinux; 128 | sway.enable = isLinux; 129 | # keep-sorted end 130 | }; 131 | } 132 | -------------------------------------------------------------------------------- /astro.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "astro/config"; 2 | import catppuccin from "@catppuccin/starlight"; 3 | import starlight from "@astrojs/starlight"; 4 | 5 | import { optionsData } from "./docs/data/options"; 6 | 7 | const starlightTitle = "catppuccin/nix"; 8 | 9 | const moduleTypeToNiceLabel = (type: string) => { 10 | switch (type) { 11 | case "nixos": 12 | return "NixOS"; 13 | case "home": 14 | return "home-manager"; 15 | default: 16 | return type; 17 | } 18 | }; 19 | 20 | const rollingVersion = "main"; 21 | const latestStableVersion = "25.05"; 22 | 23 | export default defineConfig({ 24 | site: process.env.URL || "https://nix.catppuccin.com", 25 | 26 | srcDir: "./docs", 27 | publicDir: "./docs/public", 28 | 29 | integrations: [ 30 | starlight({ 31 | title: starlightTitle, 32 | 33 | logo: { 34 | src: "./assets/logo.png", 35 | }, 36 | 37 | editLink: { 38 | baseUrl: "https://github.com/catppuccin/nix/edit/main/", 39 | }, 40 | 41 | sidebar: [ 42 | { 43 | label: starlightTitle, 44 | slug: "", 45 | }, 46 | { 47 | label: "Getting Started", 48 | autogenerate: { directory: "Getting Started" }, 49 | }, 50 | { 51 | label: "Options List", 52 | items: Object.entries(optionsData).map(([version, modules]) => { 53 | const versionGroup = { 54 | label: version, 55 | collapsed: version != rollingVersion, 56 | items: Object.entries(modules).map(([type, options]) => { 57 | return { 58 | label: moduleTypeToNiceLabel(type), 59 | collapsed: true, 60 | items: Object.keys(options).map((module) => { 61 | return { 62 | label: module, 63 | link: `/options/${version}/${type}/${module}`, 64 | }; 65 | }), 66 | }; 67 | }), 68 | }; 69 | 70 | // Apply "new" badge to latest stable release 71 | return version == latestStableVersion 72 | ? { ...versionGroup, badge: "New" } 73 | : versionGroup; 74 | }), 75 | }, 76 | { 77 | label: "Frequently Asked Questions", 78 | link: "/faq", 79 | }, 80 | { 81 | label: "Changelog", 82 | link: "/changelog", 83 | }, 84 | "contributing", 85 | ], 86 | 87 | social: [ 88 | { 89 | icon: "github", 90 | label: "GitHub", 91 | href: "https://github.com/catppuccin/nix", 92 | }, 93 | { 94 | icon: "discord", 95 | label: "Discord", 96 | href: "https://discord.com/servers/907385605422448742", 97 | }, 98 | ], 99 | 100 | // Catppuccin-ified code blocks! 101 | // Sourced from https://github.com/catppuccin/starlight/blob/e8e4bbf83541e6dc95c89b17df844b3c2c472103/apps/docs/astro.config.ts#L23-L36 102 | // TODO(@getchoo): Stop vendoring this if/when we can 103 | expressiveCode: { 104 | themes: ["catppuccin-mocha", "catppuccin-latte"], 105 | styleOverrides: { 106 | textMarkers: { 107 | insBackground: 108 | "color-mix(in oklab, var(--sl-color-green-high) 25%, var(--sl-color-gray-6));", 109 | insBorderColor: "var(--sl-color-gray-5)", 110 | delBackground: 111 | "color-mix(in oklab, var(--sl-color-red-high) 25%, var(--sl-color-gray-6));", 112 | delBorderColor: "var(--sl-color-gray-5)", 113 | }, 114 | codeBackground: "var(--sl-color-gray-6)", 115 | }, 116 | }, 117 | 118 | favicon: "./favicon.png", 119 | 120 | plugins: [catppuccin()], 121 | }), 122 | ], 123 | }); 124 | -------------------------------------------------------------------------------- /docs/content/docs/Contributing.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Contributing 3 | description: Contributing guidelines for catppuccin/nix 4 | --- 5 | 6 | ## Adding a port 7 | 8 | :::note 9 | Unofficial ports will not be accepted. All sources must be from the 10 | [Catppuccin](https://github.com/catppuccin) GitHub organization 11 | ::: 12 | 13 | Create a file in `modules//` with the name of the port. All ports should have 14 | the `catppuccin.enable` and `catppuccin.flavor` options, and optionally the 15 | `catppuccin.accent` option. `catppuccin.flavor` and `catppuccin.accent` should 16 | default to `config.catppuccin.flavor` and `config.catppuccin.accent`, respectively. 17 | When you're done, make sure to add your new file to the list in 18 | `modules//all-modules.nix` 19 | 20 | Packages can be auto-generated from our upstream sources to use in modules. 21 | This allows us to easily access, build, and auto-update all themes reliably 22 | across systems. You can add a new port to this collection using a script in the 23 | `pkgs/` folder 24 | 25 | ```bash 26 | ./pkgs/paws.py port_name 27 | ``` 28 | 29 | Alternatively -- or if your port requires a build step -- you can make your own 30 | expression with `buildCatppuccinPort`. 31 | 32 | After creating your module, add the options to enable it in `modules/tests/`. 33 | This will allow for your configuration to be tested along with the other 34 | modules automatically. 35 | 36 | 37 | 38 | Commits that add ports should be of the format 39 | 40 | ``` 41 | feat(): add support for 42 | ``` 43 | 44 | ## Commit messages 45 | 46 | This repository uses [Conventional Commits](https://conventionalcommits.org). 47 | Commit headers should be lowercase. Most commits should include a body that briefly 48 | describes the motivation and content of the commit. 49 | 50 | ### Commit types 51 | 52 | - `fix`: A bug fix that doesn't modify the public API 53 | - `feat`: A code change that modifies the public API 54 | - `refactor`: A code change that doesn't change behavior 55 | - `style`: A style fix or change 56 | - `docs`: Any change to documentation 57 | - `ci`: Any change to CI files 58 | - `revert`: A revert commit. The message should describe the reasoning and the 59 | commit should include the `Refs:` footer with the short hashes of the commits 60 | being reverted. 61 | - `chore`: catch-all type 62 | 63 | ### Commit scopes 64 | 65 | Available commit scopes are port names, `nixos`, `home-manager`, `modules`, 66 | `pkgs`, and `tests`. If none of these apply, omit the scope. 67 | 68 | ### Breaking changes 69 | 70 | All breaking changes should be documented in the commit footer in the format 71 | described by Conventional Commits. Use the `!` syntax in order to distinguish 72 | breaking commits in the log, but include the footer to provide a better description 73 | for the changelog generator. 74 | 75 | ``` 76 | feat(bar)!: foo the bars 77 | 78 | BREAKING CHANGE: bars are now foo'ed 79 | ``` 80 | 81 | ## For Maintainers 82 | 83 | ### Merging 84 | 85 | Use squash merges when reasonable. They don't pollute the log with merge commits, and 86 | unlike rebase merges, list the author as the committer as well. 87 | 88 | ### Creating Releases 89 | 90 | As of v25.05, `catppuccin/nix` tries to match the upstream releases of NixOS 91 | and home-manager. This is done through the `main` branch supporting unstable, 92 | and the `release-*` branches matching a stable release of NixOS. 93 | 94 | Tags are created on each new stable "branch-off" in the format of `vYY.MM`. 95 | **These must be created from the accompanying `release-YY.MM` branch!** A 96 | release is then created from that tag, and a changelog entry is created for all 97 | changes since the last stable branch-off with the following 98 | [`git-cliff`](https://git-cliff.org/) command: 99 | 100 | ```console 101 | $ VERSION="YY.MM" 102 | $ TAG="v${VERSION}" 103 | $ git switch "release-${VERSION}" 104 | $ git-cliff --github-token "$(gh auth token)" --prepend CHANGELOG.md --tag "$TAG" --unreleased 105 | ``` 106 | -------------------------------------------------------------------------------- /modules/home-manager/firefox.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { config, lib, ... }: 3 | let 4 | inherit (lib) 5 | attrNames 6 | foldl' 7 | hasAttr 8 | importJSON 9 | toSentenceCase 10 | mapAttrs 11 | mkIf 12 | mkOption 13 | optional 14 | getAttrFromPath 15 | setAttrByPath 16 | types 17 | ; 18 | 19 | inherit (config.catppuccin) sources; 20 | themes = importJSON "${sources.firefox}/themes.json"; 21 | 22 | mkFirefoxModule = 23 | { 24 | name, 25 | prettyName ? toSentenceCase name, 26 | hmModulePath ? [ 27 | "programs" 28 | name 29 | ], 30 | }: 31 | let 32 | modulePath = [ 33 | "catppuccin" 34 | name 35 | ]; 36 | 37 | getAttrStringFromPath = lib.concatStringsSep "."; 38 | 39 | cfg = getAttrFromPath modulePath config; 40 | firefoxCfg = getAttrFromPath hmModulePath config; 41 | 42 | mkProfileOptions = 43 | { 44 | forceDefault ? false, 45 | enableDefault ? null, 46 | }: 47 | catppuccinLib.mkCatppuccinOption ( 48 | { 49 | inherit name; 50 | accentSupport = true; 51 | } 52 | // (lib.optionalAttrs (enableDefault != null) { 53 | default = enableDefault; 54 | }) 55 | ) 56 | // { 57 | force = mkOption { 58 | type = types.bool; 59 | default = forceDefault; 60 | description = "Forcibly override any existing configuration for Firefox Color."; 61 | example = true; 62 | }; 63 | }; 64 | in 65 | { 66 | options = 67 | (setAttrByPath modulePath ( 68 | (mkProfileOptions { }) 69 | // { 70 | profiles = mkOption { 71 | type = types.attrsOf ( 72 | types.submodule { 73 | options = mkProfileOptions { 74 | enableDefault = cfg.enable; 75 | forceDefault = cfg.force; 76 | }; 77 | config = { 78 | flavor = lib.mkDefault cfg.flavor; 79 | accent = lib.mkDefault cfg.accent; 80 | }; 81 | } 82 | ); 83 | default = mapAttrs (_: _: { }) firefoxCfg.profiles; 84 | defaultText = ""; 85 | description = "Catppuccin settings for ${prettyName} profiles."; 86 | }; 87 | } 88 | )) 89 | # home-manager browser config 90 | // (setAttrByPath hmModulePath { 91 | profiles = mkOption { 92 | type = types.attrsOf ( 93 | types.submodule ( 94 | { name, ... }: 95 | let 96 | profile = cfg.profiles.${name} or { enable = false; }; 97 | in 98 | { 99 | config = mkIf profile.enable { 100 | extensions = { 101 | settings."FirefoxColor@mozilla.com" = { 102 | inherit (profile) force; 103 | settings = { 104 | firstRunDone = true; 105 | theme = themes.${profile.flavor}.${profile.accent}; 106 | }; 107 | }; 108 | }; 109 | }; 110 | } 111 | ) 112 | ); 113 | }; 114 | }); 115 | 116 | config = { 117 | warnings = foldl' ( 118 | acc: name: 119 | acc 120 | ++ 121 | optional (!(hasAttr name firefoxCfg.profiles)) 122 | "${prettyName} profile '${name}' is defined in '${getAttrStringFromPath modulePath}', but not '${getAttrStringFromPath hmModulePath}'. This will have no effect." 123 | ) [ ] (attrNames cfg.profiles); 124 | }; 125 | }; 126 | in 127 | { 128 | imports = map mkFirefoxModule [ 129 | { name = "firefox"; } 130 | { 131 | name = "librewolf"; 132 | prettyName = "LibreWolf"; # W in LibreWolf is uppercase 133 | } 134 | { name = "floorp"; } 135 | ]; 136 | } 137 | -------------------------------------------------------------------------------- /modules/nixos/sddm.nix: -------------------------------------------------------------------------------- 1 | { catppuccinLib }: 2 | { 3 | lib, 4 | pkgs, 5 | config, 6 | ... 7 | }: 8 | 9 | let 10 | inherit (lib) 11 | mkOption 12 | types 13 | ; 14 | 15 | cfg = config.catppuccin.sddm; 16 | enable = cfg.enable && config.services.displayManager.sddm.enable; 17 | in 18 | 19 | { 20 | options.catppuccin.sddm = 21 | catppuccinLib.mkCatppuccinOption { 22 | name = "sddm"; 23 | accentSupport = true; 24 | } 25 | // { 26 | font = mkOption { 27 | type = types.str; 28 | default = "Noto Sans"; 29 | description = "Font to use for the login screen"; 30 | }; 31 | 32 | fontSize = mkOption { 33 | type = types.str; 34 | default = "9"; 35 | description = "Font size to use for the login screen"; 36 | }; 37 | 38 | background = mkOption { 39 | type = with types; nullOr (either path str); 40 | default = "backgrounds/wall.png"; 41 | description = "Background image to use for the login screen"; 42 | }; 43 | 44 | loginBackground = mkOption { 45 | type = types.bool; 46 | default = false; 47 | description = "Add an additional background layer to the login panel"; 48 | }; 49 | 50 | userIcon = mkOption { 51 | type = types.bool; 52 | default = false; 53 | description = '' 54 | Enable user icon on the login screen 55 | 56 | To use this, you should place a file in `~/.face.icon` or `FacesDir/username.face.icon` 57 | ''; 58 | }; 59 | 60 | clockEnabled = mkOption { 61 | type = types.bool; 62 | default = true; 63 | description = "Enable the clock on the login screen"; 64 | }; 65 | 66 | assertQt6Sddm = 67 | lib.mkEnableOption '' 68 | checking if `services.displayManager.sddm.package` is the Qt 6 version. 69 | 70 | This is to ensure the theme is applied properly, but may have false positives in the case of overridden packages for example 71 | '' 72 | // { 73 | default = true; 74 | }; 75 | }; 76 | 77 | imports = 78 | (catppuccinLib.mkRenamedCatppuccinOptions { 79 | from = [ 80 | "services" 81 | "displayManager" 82 | "sddm" 83 | "catppuccin" 84 | ]; 85 | to = "sddm"; 86 | }) 87 | ++ [ 88 | (lib.mkRenamedOptionModule 89 | [ 90 | "services" 91 | "displayManager" 92 | "sddm" 93 | "catppuccin" 94 | "font" 95 | ] 96 | [ 97 | "catppuccin" 98 | "sddm" 99 | "font" 100 | ] 101 | ) 102 | 103 | (lib.mkRenamedOptionModule 104 | [ 105 | "services" 106 | "displayManager" 107 | "sddm" 108 | "catppuccin" 109 | "fontSize" 110 | ] 111 | [ 112 | "catppuccin" 113 | "sddm" 114 | "fontSize" 115 | ] 116 | ) 117 | 118 | (lib.mkRenamedOptionModule 119 | [ 120 | "services" 121 | "displayManager" 122 | "sddm" 123 | "catppuccin" 124 | "background" 125 | ] 126 | [ 127 | "catppuccin" 128 | "sddm" 129 | "background" 130 | ] 131 | ) 132 | 133 | (lib.mkRenamedOptionModule 134 | [ 135 | "services" 136 | "displayManager" 137 | "sddm" 138 | "catppuccin" 139 | "loginBackground" 140 | ] 141 | [ 142 | "catppuccin" 143 | "sddm" 144 | "loginBackground" 145 | ] 146 | ) 147 | 148 | (lib.mkRenamedOptionModule 149 | [ 150 | "services" 151 | "displayManager" 152 | "sddm" 153 | "catppuccin" 154 | "assertQt6Sddm" 155 | ] 156 | [ 157 | "catppuccin" 158 | "sddm" 159 | "assertQt6Sddm" 160 | ] 161 | ) 162 | 163 | (lib.mkRemovedOptionModule 164 | [ 165 | "catppuccin" 166 | "sddm" 167 | "accentColor" 168 | ] 169 | "The `accentColor` option is no longer used upstream, please migrate to the new `accent` option instead." 170 | ) 171 | ]; 172 | 173 | config = lib.mkIf enable { 174 | assertions = lib.optional cfg.assertQt6Sddm { 175 | assertion = config.services.displayManager.sddm.package == pkgs.kdePackages.sddm; 176 | message = '' 177 | Only the Qt 6 version of SDDM is supported by this port! 178 | 179 | In most cases this can be resolved by setting `services.displayManager.sddm.package` 180 | to `pkgs.kdePackages.sddm`. If you know what you're doing and wish to disable this check, 181 | please set `services.displayManager.sddm.catppuccin.assertQt6Sddm` to `false` 182 | ''; 183 | }; 184 | 185 | services.displayManager = { 186 | sddm = { 187 | theme = "catppuccin-${cfg.flavor}-${cfg.accent}"; 188 | }; 189 | }; 190 | 191 | environment.systemPackages = [ 192 | (config.catppuccin.sources.sddm.override { 193 | inherit (cfg) 194 | font 195 | fontSize 196 | background 197 | loginBackground 198 | userIcon 199 | clockEnabled 200 | ; 201 | }) 202 | ]; 203 | }; 204 | } 205 | -------------------------------------------------------------------------------- /dev/flake.nix: -------------------------------------------------------------------------------- 1 | { 2 | description = "Development Flake for catppuccin/nix"; 3 | 4 | inputs = { 5 | # WARN: This handling of `path:` is a Nix 2.26 feature. The Flake won't work correctly on versions prior to it 6 | # https://github.com/NixOS/nix/pull/10089 7 | catppuccin.url = "path:../."; 8 | nixpkgs.follows = "catppuccin/nixpkgs"; 9 | 10 | flake-utils.url = "github:numtide/flake-utils"; 11 | 12 | home-manager = { 13 | url = "github:nix-community/home-manager"; 14 | inputs.nixpkgs.follows = "nixpkgs"; 15 | }; 16 | }; 17 | 18 | outputs = 19 | { 20 | self, 21 | nixpkgs, 22 | catppuccin, 23 | ... 24 | }@inputs: 25 | 26 | let 27 | inherit (nixpkgs) lib; 28 | inherit (inputs.flake-utils.lib) eachDefaultSystem; 29 | 30 | # NOTE: Required for backwards compat with versions < 25.05 31 | homeModule = (catppuccin.homeModules or catppuccin.homeManagerModules).catppuccin; 32 | 33 | catppuccinEnableModule = 34 | { pkgs, ... }: 35 | 36 | { 37 | catppuccin = { 38 | enable = true; 39 | sources = { 40 | # this is used to ensure that we are able to apply 41 | # source overrides without breaking the other sources 42 | palette = pkgs.fetchFromGitHub { 43 | owner = "catppuccin"; 44 | repo = "palette"; 45 | rev = "16726028c518b0b94841de57cf51f14c095d43d8"; # refs/tags/1.1.1~1 46 | hash = "sha256-qZjMlZFTzJotOYjURRQMsiOdR2XGGba8XzXwx4+v9tk="; 47 | }; 48 | }; 49 | }; 50 | }; 51 | 52 | pepperjackHomeModule = 53 | { 54 | config, 55 | pkgs, 56 | osConfig, 57 | ... 58 | }: 59 | 60 | { 61 | imports = [ 62 | homeModule 63 | catppuccinEnableModule 64 | (catppuccin + "/modules/tests/home.nix") 65 | ]; 66 | 67 | home = { 68 | homeDirectory = lib.mkDefault ( 69 | if pkgs.stdenv.hostPlatform.isDarwin then 70 | "/Users/${config.home.username}" 71 | else 72 | "/home/${config.home.username}" 73 | ); 74 | # See comment in NixOS config below 75 | inherit (osConfig.system or self.nixosConfigurations.pepperjack-pc.config.system) stateVersion; 76 | }; 77 | }; 78 | in 79 | 80 | eachDefaultSystem ( 81 | system: 82 | 83 | let 84 | pkgs = nixpkgs.legacyPackages.${system}; 85 | 86 | # Evaluate each of our modules for different systems 87 | nixosConfiguration = self.nixosConfigurations.pepperjack-pc.extendModules { 88 | modules = [ 89 | ( 90 | { lib, ... }: 91 | 92 | { 93 | nixpkgs.pkgs = lib.mkForce pkgs; 94 | } 95 | ) 96 | ]; 97 | }; 98 | 99 | homeConfiguration = self.homeConfigurations.pepperjack.extendModules { 100 | modules = [ 101 | ( 102 | { lib, ... }: 103 | 104 | { 105 | _module.args.pkgs = lib.mkForce pkgs; 106 | } 107 | ) 108 | ]; 109 | }; 110 | 111 | fullEval = 112 | # NixOS includes the home-manager configuration 113 | if pkgs.stdenv.hostPlatform.isLinux then 114 | nixosConfiguration.config.system.build.toplevel.outPath 115 | else 116 | homeConfiguration.activationPackage.outPath; 117 | 118 | mkOptionsJSONFrom = 119 | eval: 120 | 121 | let 122 | # This should point to where you can view our module files 123 | filesLink = "https://github.com/catppuccin/nix/blob/${ 124 | lib.removeSuffix "-dirty" catppuccin.rev or catppuccin.dirtyRev or "main" 125 | }"; 126 | 127 | # And replace the declarations of our modules with that link 128 | rootPath = lib.removeSuffix "/dev/../." inputs.catppuccin.outPath; # HACK(@getchoo): Outpaths of subflakes are relative, womp womp 129 | replaceDeclaration = lib.replaceString rootPath filesLink; 130 | in 131 | 132 | (pkgs.nixosOptionsDoc { 133 | options = { inherit (eval.options) catppuccin; }; 134 | 135 | transformOptions = 136 | opt: lib.recursiveUpdate opt { declarations = map replaceDeclaration opt.declarations; }; 137 | }).optionsJSON; 138 | in 139 | 140 | { 141 | checks = lib.filterAttrs (lib.const lib.isDerivation) catppuccin.packages.${system} or { } // { 142 | module-eval = lib.deepSeq fullEval pkgs.emptyFile; 143 | }; 144 | 145 | packages = { 146 | nixosOptionsJSON = mkOptionsJSONFrom nixosConfiguration; 147 | homeOptionsJSON = mkOptionsJSONFrom homeConfiguration; 148 | }; 149 | } 150 | ) 151 | // ( 152 | let 153 | pkgs = nixpkgs.legacyPackages.x86_64-linux; 154 | in 155 | 156 | { 157 | homeConfigurations = { 158 | pepperjack = inputs.home-manager.lib.homeManagerConfiguration { 159 | inherit pkgs; 160 | modules = [ 161 | pepperjackHomeModule 162 | { home.username = "pepperjack"; } 163 | ]; 164 | }; 165 | }; 166 | 167 | nixosConfigurations = { 168 | pepperjack-pc = nixpkgs.lib.nixosSystem { 169 | modules = [ 170 | inputs.home-manager.nixosModules.default 171 | catppuccin.nixosModules.catppuccin 172 | catppuccinEnableModule 173 | (catppuccin + "/modules/tests/nixos.nix") 174 | 175 | ( 176 | { config, ... }: 177 | 178 | { 179 | # Silence, convenient safety assertions!!!! 180 | fileSystems."/" = { 181 | label = "root"; 182 | }; 183 | 184 | # NOTE: This isn't required for NixOS. But it is for home-manager! 185 | system.stateVersion = config.system.nixos.release; 186 | 187 | nixpkgs = { inherit pkgs; }; 188 | 189 | users.users.pepperjack = { 190 | isNormalUser = true; 191 | }; 192 | 193 | home-manager.users.pepperjack = { 194 | imports = [ pepperjackHomeModule ]; 195 | }; 196 | } 197 | ) 198 | ]; 199 | }; 200 | }; 201 | } 202 | ); 203 | } 204 | -------------------------------------------------------------------------------- /docs/data/v1.2-nixos-options.json: -------------------------------------------------------------------------------- 1 | {"catppuccin.accent": {"declarations": ["https://github.com/catppuccin/nix/blob/1e4c3803b8da874ff75224ec8512cb173036bbd8/modules/global.nix"], "default": {"_type": "literalExpression", "text": "\"mauve\""}, "description": "Global Catppuccin accent", "loc": ["catppuccin", "accent"], "readOnly": false, "type": "one of \"blue\", \"flamingo\", \"green\", \"lavender\", \"maroon\", \"mauve\", \"peach\", \"pink\", \"red\", \"rosewater\", \"sapphire\", \"sky\", \"teal\", \"yellow\""}, "catppuccin.enable": {"declarations": ["https://github.com/catppuccin/nix/blob/1e4c3803b8da874ff75224ec8512cb173036bbd8/modules/global.nix"], "default": {"_type": "literalExpression", "text": "false"}, "description": "Whether to enable Catppuccin globally.", "example": {"_type": "literalExpression", "text": "true"}, "loc": ["catppuccin", "enable"], "readOnly": false, "type": "boolean"}, "catppuccin.fcitx5.accent": {"declarations": ["https://github.com/catppuccin/nix/blob/1e4c3803b8da874ff75224ec8512cb173036bbd8/modules/nixos/fcitx5.nix"], "default": {"_type": "literalExpression", "text": "\"mauve\""}, "description": "Catppuccin accent for Fcitx5", "loc": ["catppuccin", "fcitx5", "accent"], "readOnly": false, "type": "one of \"blue\", \"flamingo\", \"green\", \"lavender\", \"maroon\", \"mauve\", \"peach\", \"pink\", \"red\", \"rosewater\", \"sapphire\", \"sky\", \"teal\", \"yellow\""}, "catppuccin.fcitx5.enable": {"declarations": ["https://github.com/catppuccin/nix/blob/1e4c3803b8da874ff75224ec8512cb173036bbd8/modules/nixos/fcitx5.nix"], "default": {"_type": "literalExpression", "text": "\"catppuccin.enable\""}, "description": "Whether to enable Catppuccin theme for Fcitx5.", "example": {"_type": "literalExpression", "text": "true"}, "loc": ["catppuccin", "fcitx5", "enable"], "readOnly": false, "type": "boolean"}, "catppuccin.fcitx5.flavor": {"declarations": ["https://github.com/catppuccin/nix/blob/1e4c3803b8da874ff75224ec8512cb173036bbd8/modules/nixos/fcitx5.nix"], "default": {"_type": "literalExpression", "text": "\"mocha\""}, "description": "Catppuccin flavor for Fcitx5", "loc": ["catppuccin", "fcitx5", "flavor"], "readOnly": false, "type": "one of \"latte\", \"frappe\", \"macchiato\", \"mocha\""}, "catppuccin.flavor": {"declarations": ["https://github.com/catppuccin/nix/blob/1e4c3803b8da874ff75224ec8512cb173036bbd8/modules/global.nix"], "default": {"_type": "literalExpression", "text": "\"mocha\""}, "description": "Global Catppuccin flavor", "loc": ["catppuccin", "flavor"], "readOnly": false, "type": "one of \"latte\", \"frappe\", \"macchiato\", \"mocha\""}, "catppuccin.grub.enable": {"declarations": ["https://github.com/catppuccin/nix/blob/1e4c3803b8da874ff75224ec8512cb173036bbd8/modules/nixos/grub.nix"], "default": {"_type": "literalExpression", "text": "\"catppuccin.enable\""}, "description": "Whether to enable Catppuccin theme for grub.", "example": {"_type": "literalExpression", "text": "true"}, "loc": ["catppuccin", "grub", "enable"], "readOnly": false, "type": "boolean"}, "catppuccin.grub.flavor": {"declarations": ["https://github.com/catppuccin/nix/blob/1e4c3803b8da874ff75224ec8512cb173036bbd8/modules/nixos/grub.nix"], "default": {"_type": "literalExpression", "text": "\"mocha\""}, "description": "Catppuccin flavor for grub", "loc": ["catppuccin", "grub", "flavor"], "readOnly": false, "type": "one of \"latte\", \"frappe\", \"macchiato\", \"mocha\""}, "catppuccin.plymouth.enable": {"declarations": ["https://github.com/catppuccin/nix/blob/1e4c3803b8da874ff75224ec8512cb173036bbd8/modules/nixos/plymouth.nix"], "default": {"_type": "literalExpression", "text": "\"catppuccin.enable\""}, "description": "Whether to enable Catppuccin theme for plymouth.", "example": {"_type": "literalExpression", "text": "true"}, "loc": ["catppuccin", "plymouth", "enable"], "readOnly": false, "type": "boolean"}, "catppuccin.plymouth.flavor": {"declarations": ["https://github.com/catppuccin/nix/blob/1e4c3803b8da874ff75224ec8512cb173036bbd8/modules/nixos/plymouth.nix"], "default": {"_type": "literalExpression", "text": "\"mocha\""}, "description": "Catppuccin flavor for plymouth", "loc": ["catppuccin", "plymouth", "flavor"], "readOnly": false, "type": "one of \"latte\", \"frappe\", \"macchiato\", \"mocha\""}, "catppuccin.sddm.assertQt6Sddm": {"declarations": ["https://github.com/catppuccin/nix/blob/1e4c3803b8da874ff75224ec8512cb173036bbd8/modules/nixos/sddm.nix"], "default": {"_type": "literalExpression", "text": "true"}, "description": "Whether to enable checking if `services.displayManager.sddm.package` is the Qt 6 version.\n\nThis is to ensure the theme is applied properly, but may have false positives in the case of overridden packages for example\n.", "example": {"_type": "literalExpression", "text": "true"}, "loc": ["catppuccin", "sddm", "assertQt6Sddm"], "readOnly": false, "type": "boolean"}, "catppuccin.sddm.background": {"declarations": ["https://github.com/catppuccin/nix/blob/1e4c3803b8da874ff75224ec8512cb173036bbd8/modules/nixos/sddm.nix"], "default": {"_type": "literalExpression", "text": "\"\""}, "description": "Background image to use for the login screen", "loc": ["catppuccin", "sddm", "background"], "readOnly": false, "type": "absolute path or string"}, "catppuccin.sddm.enable": {"declarations": ["https://github.com/catppuccin/nix/blob/1e4c3803b8da874ff75224ec8512cb173036bbd8/modules/nixos/sddm.nix"], "default": {"_type": "literalExpression", "text": "\"catppuccin.enable\""}, "description": "Whether to enable Catppuccin theme for sddm.", "example": {"_type": "literalExpression", "text": "true"}, "loc": ["catppuccin", "sddm", "enable"], "readOnly": false, "type": "boolean"}, "catppuccin.sddm.flavor": {"declarations": ["https://github.com/catppuccin/nix/blob/1e4c3803b8da874ff75224ec8512cb173036bbd8/modules/nixos/sddm.nix"], "default": {"_type": "literalExpression", "text": "\"mocha\""}, "description": "Catppuccin flavor for sddm", "loc": ["catppuccin", "sddm", "flavor"], "readOnly": false, "type": "one of \"latte\", \"frappe\", \"macchiato\", \"mocha\""}, "catppuccin.sddm.font": {"declarations": ["https://github.com/catppuccin/nix/blob/1e4c3803b8da874ff75224ec8512cb173036bbd8/modules/nixos/sddm.nix"], "default": {"_type": "literalExpression", "text": "\"Noto Sans\""}, "description": "Font to use for the login screen", "loc": ["catppuccin", "sddm", "font"], "readOnly": false, "type": "string"}, "catppuccin.sddm.fontSize": {"declarations": ["https://github.com/catppuccin/nix/blob/1e4c3803b8da874ff75224ec8512cb173036bbd8/modules/nixos/sddm.nix"], "default": {"_type": "literalExpression", "text": "\"9\""}, "description": "Font size to use for the login screen", "loc": ["catppuccin", "sddm", "fontSize"], "readOnly": false, "type": "string"}, "catppuccin.sddm.loginBackground": {"declarations": ["https://github.com/catppuccin/nix/blob/1e4c3803b8da874ff75224ec8512cb173036bbd8/modules/nixos/sddm.nix"], "default": {"_type": "literalExpression", "text": "true"}, "description": "Add an additional background layer to the login panel", "loc": ["catppuccin", "sddm", "loginBackground"], "readOnly": false, "type": "boolean"}, "catppuccin.sources": {"declarations": ["https://github.com/catppuccin/nix/blob/1e4c3803b8da874ff75224ec8512cb173036bbd8/modules/global.nix"], "default": {"_type": "literalExpression", "text": "\"{ ... }\""}, "description": "Port sources used across all options", "loc": ["catppuccin", "sources"], "readOnly": false, "type": "lazy attribute set of raw value"}, "catppuccin.tty.enable": {"declarations": ["https://github.com/catppuccin/nix/blob/1e4c3803b8da874ff75224ec8512cb173036bbd8/modules/nixos/tty.nix"], "default": {"_type": "literalExpression", "text": "\"catppuccin.enable\""}, "description": "Whether to enable Catppuccin theme for console.", "example": {"_type": "literalExpression", "text": "true"}, "loc": ["catppuccin", "tty", "enable"], "readOnly": false, "type": "boolean"}, "catppuccin.tty.flavor": {"declarations": ["https://github.com/catppuccin/nix/blob/1e4c3803b8da874ff75224ec8512cb173036bbd8/modules/nixos/tty.nix"], "default": {"_type": "literalExpression", "text": "\"mocha\""}, "description": "Catppuccin flavor for console", "loc": ["catppuccin", "tty", "flavor"], "readOnly": false, "type": "one of \"latte\", \"frappe\", \"macchiato\", \"mocha\""}} -------------------------------------------------------------------------------- /docs/data/v1.1-nixos-options.json: -------------------------------------------------------------------------------- 1 | {"boot.loader.grub.catppuccin.enable": {"declarations": ["https://github.com/catppuccin/nix/blob/7221d6ca17ac36ed20588e1c3a80177ac5843fa7/modules/nixos/grub.nix"], "default": {"_type": "literalExpression", "text": "false"}, "description": "Whether to enable Catppuccin theme for grub.", "example": {"_type": "literalExpression", "text": "true"}, "loc": ["boot", "loader", "grub", "catppuccin", "enable"], "readOnly": false, "type": "boolean"}, "boot.loader.grub.catppuccin.flavor": {"declarations": ["https://github.com/catppuccin/nix/blob/7221d6ca17ac36ed20588e1c3a80177ac5843fa7/modules/nixos/grub.nix"], "default": {"_type": "literalExpression", "text": "\"mocha\""}, "description": "Catppuccin flavor for grub", "loc": ["boot", "loader", "grub", "catppuccin", "flavor"], "readOnly": false, "type": "one of \"latte\", \"frappe\", \"macchiato\", \"mocha\""}, "boot.plymouth.catppuccin.enable": {"declarations": ["https://github.com/catppuccin/nix/blob/7221d6ca17ac36ed20588e1c3a80177ac5843fa7/modules/nixos/plymouth.nix"], "default": {"_type": "literalExpression", "text": "false"}, "description": "Whether to enable Catppuccin theme for plymouth.", "example": {"_type": "literalExpression", "text": "true"}, "loc": ["boot", "plymouth", "catppuccin", "enable"], "readOnly": false, "type": "boolean"}, "boot.plymouth.catppuccin.flavor": {"declarations": ["https://github.com/catppuccin/nix/blob/7221d6ca17ac36ed20588e1c3a80177ac5843fa7/modules/nixos/plymouth.nix"], "default": {"_type": "literalExpression", "text": "\"mocha\""}, "description": "Catppuccin flavor for plymouth", "loc": ["boot", "plymouth", "catppuccin", "flavor"], "readOnly": false, "type": "one of \"latte\", \"frappe\", \"macchiato\", \"mocha\""}, "catppuccin.accent": {"declarations": ["https://github.com/catppuccin/nix/blob/7221d6ca17ac36ed20588e1c3a80177ac5843fa7/modules/nixos/globals.nix"], "default": {"_type": "literalExpression", "text": "\"mauve\""}, "description": "Global Catppuccin accent", "loc": ["catppuccin", "accent"], "readOnly": false, "type": "one of \"blue\", \"flamingo\", \"green\", \"lavender\", \"maroon\", \"mauve\", \"peach\", \"pink\", \"red\", \"rosewater\", \"sapphire\", \"sky\", \"teal\", \"yellow\""}, "catppuccin.enable": {"declarations": ["https://github.com/catppuccin/nix/blob/7221d6ca17ac36ed20588e1c3a80177ac5843fa7/modules/nixos/globals.nix"], "default": {"_type": "literalExpression", "text": "false"}, "description": "Whether to enable Catppuccin globally.", "example": {"_type": "literalExpression", "text": "true"}, "loc": ["catppuccin", "enable"], "readOnly": false, "type": "boolean"}, "catppuccin.flavor": {"declarations": ["https://github.com/catppuccin/nix/blob/7221d6ca17ac36ed20588e1c3a80177ac5843fa7/modules/nixos/globals.nix"], "default": {"_type": "literalExpression", "text": "\"mocha\""}, "description": "Global Catppuccin flavor", "loc": ["catppuccin", "flavor"], "readOnly": false, "type": "one of \"latte\", \"frappe\", \"macchiato\", \"mocha\""}, "catppuccin.sources": {"declarations": ["https://github.com/catppuccin/nix/blob/7221d6ca17ac36ed20588e1c3a80177ac5843fa7/modules/nixos/globals.nix"], "default": {"_type": "literalExpression", "text": "\"{ ... }\""}, "description": "Port sources used across all options", "loc": ["catppuccin", "sources"], "readOnly": false, "type": "lazy attribute set of raw value"}, "console.catppuccin.enable": {"declarations": ["https://github.com/catppuccin/nix/blob/7221d6ca17ac36ed20588e1c3a80177ac5843fa7/modules/nixos/console.nix"], "default": {"_type": "literalExpression", "text": "false"}, "description": "Whether to enable Catppuccin theme for console.", "example": {"_type": "literalExpression", "text": "true"}, "loc": ["console", "catppuccin", "enable"], "readOnly": false, "type": "boolean"}, "console.catppuccin.flavor": {"declarations": ["https://github.com/catppuccin/nix/blob/7221d6ca17ac36ed20588e1c3a80177ac5843fa7/modules/nixos/console.nix"], "default": {"_type": "literalExpression", "text": "\"mocha\""}, "description": "Catppuccin flavor for console", "loc": ["console", "catppuccin", "flavor"], "readOnly": false, "type": "one of \"latte\", \"frappe\", \"macchiato\", \"mocha\""}, "i18n.inputMethod.fcitx5.catppuccin.accent": {"declarations": ["https://github.com/catppuccin/nix/blob/7221d6ca17ac36ed20588e1c3a80177ac5843fa7/modules/nixos/fcitx5.nix"], "default": {"_type": "literalExpression", "text": "\"mauve\""}, "description": "Catppuccin accent for Fcitx5", "loc": ["i18n", "inputMethod", "fcitx5", "catppuccin", "accent"], "readOnly": false, "type": "one of \"blue\", \"flamingo\", \"green\", \"lavender\", \"maroon\", \"mauve\", \"peach\", \"pink\", \"red\", \"rosewater\", \"sapphire\", \"sky\", \"teal\", \"yellow\""}, "i18n.inputMethod.fcitx5.catppuccin.enable": {"declarations": ["https://github.com/catppuccin/nix/blob/7221d6ca17ac36ed20588e1c3a80177ac5843fa7/modules/nixos/fcitx5.nix"], "default": {"_type": "literalExpression", "text": "false"}, "description": "Whether to enable Catppuccin theme for Fcitx5.", "example": {"_type": "literalExpression", "text": "true"}, "loc": ["i18n", "inputMethod", "fcitx5", "catppuccin", "enable"], "readOnly": false, "type": "boolean"}, "i18n.inputMethod.fcitx5.catppuccin.flavor": {"declarations": ["https://github.com/catppuccin/nix/blob/7221d6ca17ac36ed20588e1c3a80177ac5843fa7/modules/nixos/fcitx5.nix"], "default": {"_type": "literalExpression", "text": "\"mocha\""}, "description": "Catppuccin flavor for Fcitx5", "loc": ["i18n", "inputMethod", "fcitx5", "catppuccin", "flavor"], "readOnly": false, "type": "one of \"latte\", \"frappe\", \"macchiato\", \"mocha\""}, "services.displayManager.sddm.catppuccin.assertQt6Sddm": {"declarations": ["https://github.com/catppuccin/nix/blob/7221d6ca17ac36ed20588e1c3a80177ac5843fa7/modules/nixos/sddm.nix"], "default": {"_type": "literalExpression", "text": "true"}, "description": "Whether to enable checking if `services.displayManager.sddm.package` is the Qt 6 version.\n\nThis is to ensure the theme is applied properly, but may have false positives in the case of overridden packages for example\n.", "example": {"_type": "literalExpression", "text": "true"}, "loc": ["services", "displayManager", "sddm", "catppuccin", "assertQt6Sddm"], "readOnly": false, "type": "boolean"}, "services.displayManager.sddm.catppuccin.background": {"declarations": ["https://github.com/catppuccin/nix/blob/7221d6ca17ac36ed20588e1c3a80177ac5843fa7/modules/nixos/sddm.nix"], "default": {"_type": "literalExpression", "text": "\"\""}, "description": "Background image to use for the login screen", "loc": ["services", "displayManager", "sddm", "catppuccin", "background"], "readOnly": false, "type": "absolute path or string"}, "services.displayManager.sddm.catppuccin.enable": {"declarations": ["https://github.com/catppuccin/nix/blob/7221d6ca17ac36ed20588e1c3a80177ac5843fa7/modules/nixos/sddm.nix"], "default": {"_type": "literalExpression", "text": "false"}, "description": "Whether to enable Catppuccin theme for sddm.", "example": {"_type": "literalExpression", "text": "true"}, "loc": ["services", "displayManager", "sddm", "catppuccin", "enable"], "readOnly": false, "type": "boolean"}, "services.displayManager.sddm.catppuccin.flavor": {"declarations": ["https://github.com/catppuccin/nix/blob/7221d6ca17ac36ed20588e1c3a80177ac5843fa7/modules/nixos/sddm.nix"], "default": {"_type": "literalExpression", "text": "\"mocha\""}, "description": "Catppuccin flavor for sddm", "loc": ["services", "displayManager", "sddm", "catppuccin", "flavor"], "readOnly": false, "type": "one of \"latte\", \"frappe\", \"macchiato\", \"mocha\""}, "services.displayManager.sddm.catppuccin.font": {"declarations": ["https://github.com/catppuccin/nix/blob/7221d6ca17ac36ed20588e1c3a80177ac5843fa7/modules/nixos/sddm.nix"], "default": {"_type": "literalExpression", "text": "\"Noto Sans\""}, "description": "Font to use for the login screen", "loc": ["services", "displayManager", "sddm", "catppuccin", "font"], "readOnly": false, "type": "string"}, "services.displayManager.sddm.catppuccin.fontSize": {"declarations": ["https://github.com/catppuccin/nix/blob/7221d6ca17ac36ed20588e1c3a80177ac5843fa7/modules/nixos/sddm.nix"], "default": {"_type": "literalExpression", "text": "\"9\""}, "description": "Font size to use for the login screen", "loc": ["services", "displayManager", "sddm", "catppuccin", "fontSize"], "readOnly": false, "type": "string"}, "services.displayManager.sddm.catppuccin.loginBackground": {"declarations": ["https://github.com/catppuccin/nix/blob/7221d6ca17ac36ed20588e1c3a80177ac5843fa7/modules/nixos/sddm.nix"], "default": {"_type": "literalExpression", "text": "true"}, "description": "Add an additional background layer to the login panel", "loc": ["services", "displayManager", "sddm", "catppuccin", "loginBackground"], "readOnly": false, "type": "boolean"}} --------------------------------------------------------------------------------