2023-09-11 22:38:24 +00:00
|
|
|
{
|
|
|
|
inputs.nixpkgs.url = "github:NixOS/nixpkgs/23.05";
|
|
|
|
|
|
|
|
outputs = { self, nixpkgs }: let
|
|
|
|
system = "x86_64-linux";
|
2023-09-17 00:24:51 +00:00
|
|
|
patched = (import nixpkgs { inherit system; }).applyPatches {
|
|
|
|
name = "nixpkgs+247773";
|
|
|
|
src = nixpkgs;
|
|
|
|
patches = [
|
|
|
|
./patches/b6910512a0789390af9db312ee8f08665bd662ab.patch
|
|
|
|
./patches/f23952856444fe39fad622a0db9eae55cd0f6fe8.patch
|
|
|
|
./patches/095afd88c41f08cb37e9cd67429baaa8d02e2d6f.patch
|
|
|
|
];
|
|
|
|
};
|
|
|
|
pkgs = import patched { inherit system; };
|
|
|
|
#pkgs = nixpkgs.legacyPackages.${system};
|
2023-09-11 22:38:24 +00:00
|
|
|
pyenv = pkgs.python3.withPackages (pypkgs: [
|
|
|
|
pypkgs.markdown
|
|
|
|
pypkgs.beautifulsoup4
|
2023-09-19 19:28:15 +00:00
|
|
|
pypkgs.feedgen
|
2023-09-11 22:38:24 +00:00
|
|
|
]);
|
|
|
|
in {
|
2023-09-19 19:28:15 +00:00
|
|
|
packages.${system} = {
|
|
|
|
inherit pyenv;
|
|
|
|
};
|
|
|
|
|
2023-09-11 22:38:24 +00:00
|
|
|
devShells.${system} = {
|
|
|
|
default = pkgs.mkShell {
|
2023-09-12 03:07:12 +00:00
|
|
|
packages = [
|
|
|
|
pyenv
|
2023-09-20 03:32:45 +00:00
|
|
|
pkgs.inotify-tools
|
2023-09-12 03:07:12 +00:00
|
|
|
pkgs.rsync
|
2023-09-17 00:24:51 +00:00
|
|
|
pkgs.pagefind
|
2023-09-12 03:07:12 +00:00
|
|
|
];
|
2023-12-18 17:51:03 +00:00
|
|
|
shellHook = ''
|
|
|
|
echo "make build - compile src/ into out/ with pagefind"
|
|
|
|
echo "make clean - delete out/ and srv/"
|
|
|
|
echo "make watch - rebuild on changes"
|
|
|
|
echo "make serve - serve out/"
|
|
|
|
echo "make pubdate - replace 'now' with the current date"
|
|
|
|
echo "make upload - build to srv/ and upload to alogoulogoi"
|
|
|
|
'';
|
2023-09-11 22:38:24 +00:00
|
|
|
};
|
|
|
|
};
|
|
|
|
};
|
|
|
|
}
|