diff --git a/default.nix b/default.nix new file mode 100644 index 0000000..f817afa --- /dev/null +++ b/default.nix @@ -0,0 +1,11 @@ +# Make this flake based dir work like a normal derivation: +# https://nixos.wiki/wiki/Flakes#Using_flakes_with_stable_Nix +(import ( + let + lock = builtins.fromJSON (builtins.readFile ./flake.lock); + in fetchTarball { + url = "https://github.com/edolstra/flake-compat/archive/${lock.nodes.flake-compat.locked.rev}.tar.gz"; + sha256 = lock.nodes.flake-compat.locked.narHash; } +) { + src = ./.; +}).defaultNix diff --git a/flake.nix b/flake.nix index f10eae4..c5ba056 100644 --- a/flake.nix +++ b/flake.nix @@ -3,6 +3,10 @@ description = "My personal website"; inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixos-23.11"; inputs.flake-utils.url = "github:numtide/flake-utils"; + inputs.flake-compat = { + url = "github:edolstra/flake-compat"; + flake = false; + }; outputs = { self, nixpkgs, flake-utils }: flake-utils.lib.eachDefaultSystem (system: