From 20b9536605160f910ff5d7368c0cf534e780e8ac Mon Sep 17 00:00:00 2001 From: Jakob Kokel Date: Sat, 1 Aug 2026 11:09:48 +0200 Subject: [PATCH] Add Nix flake packaging for Colloid GTK theme --- flake.lock | 27 +++++++++++++++++++++++++++ flake.nix | 20 ++++++++++++++++++++ nix/default.nix | 39 +++++++++++++++++++++++++++++++++++++++ 3 files changed, 86 insertions(+) create mode 100644 flake.lock create mode 100644 flake.nix create mode 100644 nix/default.nix diff --git a/flake.lock b/flake.lock new file mode 100644 index 00000000..e6d08bb9 --- /dev/null +++ b/flake.lock @@ -0,0 +1,27 @@ +{ + "nodes": { + "nixpkgs": { + "locked": { + "lastModified": 1785454630, + "narHash": "sha256-LQy14TZp77TwbQf40gg1V3jo8FwJG0jGDkAH+zRHqg8=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "1559d3daa3ecc813a650b79375ea61b6741b8746", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "nixos-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, + "root": { + "inputs": { + "nixpkgs": "nixpkgs" + } + } + }, + "root": "root", + "version": 7 +} diff --git a/flake.nix b/flake.nix new file mode 100644 index 00000000..fab7845d --- /dev/null +++ b/flake.nix @@ -0,0 +1,20 @@ +{ + description = "Modern and clean Gtk theme"; + + inputs = { + nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable"; + }; + + outputs = { self, nixpkgs }: + let + system = "x86_64-linux"; + + pkgs = import nixpkgs { + inherit system; + }; + + in { + packages.${system}.default = + pkgs.callPackage ./nix/default.nix {}; + }; +} diff --git a/nix/default.nix b/nix/default.nix new file mode 100644 index 00000000..4b85480a --- /dev/null +++ b/nix/default.nix @@ -0,0 +1,39 @@ +{ lib +, stdenv +, bash +, coreutils +, sassc +, ... +}: + +stdenv.mkDerivation { + pname = "colloid-gtk-theme"; + version = "3.6.2"; + + src = ../.; + + nativeBuildInputs = [ + bash + coreutils + sassc + ]; + + patchPhase = '' + patchShebangs install.sh + ''; + + installPhase = '' + runHook preInstall + + HOME="$TMPDIR" ./install.sh \ + --dest $out/share/themes + + runHook postInstall + ''; + + meta = { + description = "Colloid GTK Theme"; + license = lib.licenses.gpl3; + platforms = lib.platforms.linux; + }; +}