clan-homepage/flake.nix

34 lines
852 B
Nix
Raw Normal View History

2023-07-05 11:22:58 +00:00
{
description = "Website of the clan project";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
flake-parts.url = "github:hercules-ci/flake-parts";
};
outputs = inputs@{ self, flake-parts, ... }:
flake-parts.lib.mkFlake { inherit inputs; } ({ lib, ... }: {
systems = lib.systems.flakeExposed;
2023-07-17 21:21:54 +00:00
imports = [
./flake-parts/deploy.nix
];
2023-07-05 11:22:58 +00:00
perSystem = { pkgs, ... }: {
packages.default = pkgs.runCommand "website" {
buildInputs = [ pkgs.zola ];
} ''
mkdir -p $out
2023-07-05 11:24:32 +00:00
cp -r ${self}/* .
2023-07-05 11:22:58 +00:00
chmod -R u+w .
zola build
2023-07-13 17:07:46 +00:00
cp -r public/* public/.* $out
2023-07-05 11:22:58 +00:00
'';
devShells.default = pkgs.mkShell {
packages = [
pkgs.bashInteractive
pkgs.zola
];
};
};
});
}