add hugo flake

This commit is contained in:
aditya 2023-06-07 10:58:24 +05:30
parent d1116d5ec9
commit 4e87381c8b
Signed by: aditya
SSH key fingerprint: SHA256:jL1IvWsjjlPtw6HvDIHfXfhO9IkIokNEyIfuFhSdoyU

19
flake-hugo.nix Normal file
View file

@ -0,0 +1,19 @@
{
description = "A flake for publishing blog posts to https://blog.adityakumar.xyz/";
inputs.nixpkgs.url = "github:nixos/nixpkgs/23.05";
outputs = { self, nixpkgs }: {
packages.x86_64-linux.default = with import nixpkgs { system = "x86_64-linux"; };
stdenv.mkDerivation {
name = "blog";
buildInputs = [
pkgs.hugo
pkgs.rsync
];
src = self;
buildPhase = "hugo server";
installPhase = "./deploy.sh";
};
};
}