summaryrefslogtreecommitdiff
path: root/default.nix
diff options
context:
space:
mode:
authorGuillaume Boisseau2024-04-18 11:17:40 +0200
committerGitHub2024-04-18 11:17:40 +0200
commitb4c3829305cac70827f6cbca2e90b0ef8be00d47 (patch)
tree4872b0d16d71e7ddc61c30639e7130896244cce1 /default.nix
parent6b075d3bfa8f8c28fe706ee79c2beb20d58ea946 (diff)
parent75efc0213100f405fa64f3362e2fc4a73d09f61e (diff)
Merge pull request #145 from RaitoBezarius/no-flakes
Diffstat (limited to 'default.nix')
-rw-r--r--default.nix16
1 files changed, 16 insertions, 0 deletions
diff --git a/default.nix b/default.nix
new file mode 100644
index 00000000..d7da8cd1
--- /dev/null
+++ b/default.nix
@@ -0,0 +1,16 @@
+# This file provides backward compatibility to nix < 2.4 clients
+{ system ? builtins.currentSystem }:
+let
+ lock = builtins.fromJSON (builtins.readFile ./flake.lock);
+
+ inherit (lock.nodes.flake-compat.locked) owner repo rev narHash;
+
+ flake-compat = fetchTarball {
+ url = "https://github.com/${owner}/${repo}/archive/${rev}.tar.gz";
+ sha256 = narHash;
+ };
+
+ flake = import flake-compat { inherit system; src = ./.; };
+in
+flake.defaultNix
+