2024-04-14 18:39:55 +08:00
|
|
|
{
|
|
|
|
description = "A pack of GRUB2 themes for Honkai: Star Rail";
|
|
|
|
|
|
|
|
inputs = {
|
|
|
|
nixpkgs.url = "github:nixos/nixpkgs?ref=nixos-unstable";
|
|
|
|
flake-utils.url = "github:numtide/flake-utils";
|
|
|
|
};
|
|
|
|
|
|
|
|
outputs = { self, nixpkgs, flake-utils }:
|
|
|
|
let
|
|
|
|
systems = [ "aarch64-linux" "i686-linux" "x86_64-linux" ];
|
|
|
|
in
|
|
|
|
flake-utils.lib.eachSystem systems (system:
|
|
|
|
let
|
|
|
|
pkgs = import nixpkgs { inherit system; };
|
|
|
|
|
|
|
|
themeNames = builtins.attrNames (builtins.readDir ./assets/themes);
|
|
|
|
themePackages = builtins.listToAttrs (builtins.map
|
2024-04-14 18:51:24 +08:00
|
|
|
(theme:
|
|
|
|
let
|
2024-04-14 18:53:44 +08:00
|
|
|
name = (builtins.replaceStrings [ "." ] [ "_" ] (pkgs.lib.strings.toLower theme)) + "-grub-theme";
|
2024-04-14 18:51:24 +08:00
|
|
|
in
|
|
|
|
{
|
|
|
|
inherit name;
|
|
|
|
value = pkgs.callPackage ./default.nix { inherit theme; };
|
|
|
|
})
|
2024-04-14 18:39:55 +08:00
|
|
|
themeNames);
|
|
|
|
in
|
|
|
|
{
|
|
|
|
packages = {
|
|
|
|
default = pkgs.callPackage ./default.nix { theme = "Acheron"; };
|
|
|
|
} // themePackages;
|
|
|
|
|
|
|
|
devShells.default = pkgs.mkShell {
|
2024-04-16 02:57:07 +08:00
|
|
|
nativeBuildInputs = with pkgs; [ nixpkgs-fmt nixd act ];
|
2024-04-14 18:39:55 +08:00
|
|
|
};
|
|
|
|
|
|
|
|
nixosModules.default = ./module.nix;
|
|
|
|
});
|
|
|
|
}
|