From 4e87381c8b73e73b730954455b0bd803a68d92a6 Mon Sep 17 00:00:00 2001 From: aditya Date: Wed, 7 Jun 2023 10:58:24 +0530 Subject: [PATCH] add hugo flake --- flake-hugo.nix | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 flake-hugo.nix diff --git a/flake-hugo.nix b/flake-hugo.nix new file mode 100644 index 0000000..78f63be --- /dev/null +++ b/flake-hugo.nix @@ -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"; + }; + }; +}