2024-03-10 16:22:24 +01:00
|
|
|
{ description = "Extremely basic flake";
|
|
|
|
inputs = {
|
|
|
|
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
|
|
|
flake-utils.url = "github:numtide/flake-utils";
|
2024-03-29 18:51:53 +01:00
|
|
|
twin = {
|
|
|
|
url = "git+https://forge.antimattercloud.nl/Egg/twin";
|
|
|
|
inputs.nixpkgs.follows = "nixpkgs";
|
|
|
|
};
|
2024-03-10 16:22:24 +01:00
|
|
|
};
|
2024-03-29 18:51:53 +01:00
|
|
|
outputs = { self, nixpkgs, flake-utils, twin }:
|
2024-03-10 16:22:24 +01:00
|
|
|
flake-utils.lib.eachDefaultSystem (system:
|
|
|
|
let pkgs = import nixpkgs { inherit system; };
|
|
|
|
in {
|
|
|
|
packages = {
|
|
|
|
antimatter = pkgs.stdenvNoCC.mkDerivation rec {
|
|
|
|
pname = "antigem";
|
2024-03-29 18:51:53 +01:00
|
|
|
version = "0.2";
|
2024-03-10 16:22:24 +01:00
|
|
|
src = ./antimattercloud;
|
|
|
|
|
2024-03-29 18:51:53 +01:00
|
|
|
nativeBuildInputs = [
|
|
|
|
twin.packages.${system}.default
|
|
|
|
];
|
|
|
|
|
|
|
|
buildPhase = ''
|
|
|
|
twin -d story-snippets -t Stories -nb '/' > stories.gmi
|
|
|
|
'';
|
|
|
|
|
2024-03-10 16:22:24 +01:00
|
|
|
installPhase = ''
|
|
|
|
mkdir -p $out/share/${pname}
|
|
|
|
cp -r . $out/share/${pname}
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
};
|
|
|
|
});
|
|
|
|
}
|