diff --git a/.gitignore b/.gitignore index d505bd4..c4a847d 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1 @@ /result -# we ignore flake.lock because this isn't intended to pin a specific version of nixpkgs -/flake.lock diff --git a/default.nix b/default.nix index 91936d3..64fe8a8 100644 --- a/default.nix +++ b/default.nix @@ -1,5 +1,22 @@ -{ ... }: -{ - imports = [ ./module.nix ]; - nixpkgs.overlays = import ./overlay.nix; -} +let + lockFile = builtins.fromJSON (builtins.readFile ./flake.lock); + nixpkgs = builtins.fetchTarball { + url = ""; + sha256 = lockFile.nodes.nixpkgs.locked.narHash; + }; + lix = builtins.fetchTarball { + url = ""; + sha256 = lockFile.nodes.lix.locked.narHash; + }; + lix-module = builtins.fetchTarball { + url = ""; + sha256 = lockFile.nodes.lix-module.locked.narHash; + }; +in +args: + import "${nixpkgs}" { + overlays = [ + (import ./overlay.nix) + (import "${lix-module}/overlay.nix" { inherit lix; }) + ] ++ args.overlays; + } // (builtins.removeAttrs args [ "overlays" ]) diff --git a/flake.lock b/flake.lock new file mode 100644 index 0000000..8908c6e --- /dev/null +++ b/flake.lock @@ -0,0 +1,57 @@ +{ + "nodes": { + "lix": { + "flake": false, + "locked": { + "lastModified": 1723503926, + "narHash": "sha256-Rosl9iA9MybF5Bud4BTAQ9adbY81aGmPfV8dDBGl34s=", + "rev": "bcaeb6388b8916ac6d1736e3aa2b13313e6a6bd2", + "type": "tarball", + "url": "https://git.lix.systems/api/v1/repos/lix-project/lix/archive/bcaeb6388b8916ac6d1736e3aa2b13313e6a6bd2.tar.gz?rev=bcaeb6388b8916ac6d1736e3aa2b13313e6a6bd2" + }, + "original": { + "type": "tarball", + "url": "https://git.lix.systems/lix-project/lix/archive/2.91.0.tar.gz" + } + }, + "lix-module": { + "flake": false, + "locked": { + "lastModified": 1723510904, + "narHash": "sha256-zNW/rqNJwhq2lYmQf19wJerRuNimjhxHKmzrWWFJYts=", + "rev": "622a2253a071a1fb97a4d3c8103a91114acc1140", + "type": "tarball", + "url": "https://git.lix.systems/api/v1/repos/lix-project/nixos-module/archive/622a2253a071a1fb97a4d3c8103a91114acc1140.tar.gz?rev=622a2253a071a1fb97a4d3c8103a91114acc1140" + }, + "original": { + "type": "tarball", + "url": "https://git.lix.systems/lix-project/nixos-module/archive/2.91.0.tar.gz" + } + }, + "nixpkgs": { + "locked": { + "lastModified": 1729256560, + "narHash": "sha256-/uilDXvCIEs3C9l73JTACm4quuHUsIHcns1c+cHUJwA=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "4c2fcb090b1f3e5b47eaa7bd33913b574a11e0a0", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "nixos-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, + "root": { + "inputs": { + "lix": "lix", + "lix-module": "lix-module", + "nixpkgs": "nixpkgs" + } + } + }, + "root": "root", + "version": 7 +} diff --git a/flake.nix b/flake.nix index 0e3a406..46e8d94 100644 --- a/flake.nix +++ b/flake.nix @@ -2,6 +2,8 @@ description = "dragnpkgs together with nixpkgs and lix"; inputs = { + nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable"; + lix-module = { url = "https://git.lix.systems/lix-project/nixos-module/archive/2.91.0.tar.gz"; flake = false;