feat: introduce our own flake-compat

Signed-off-by: Raito Bezarius <raito@lix.systems>
This commit is contained in:
raito 2024-03-09 01:48:11 +01:00
parent 3fe47ad3f3
commit 3ddd6e5e79
3 changed files with 28 additions and 1 deletions

10
default.nix Normal file
View file

@ -0,0 +1,10 @@
(import
(
let lock = builtins.fromJSON (builtins.readFile ./flake.lock); in
fetchTarball {
url = lock.nodes.flake-compat.locked.url or "https://git.lix.systems/lix-project/flake-compat/archive/${lock.nodes.flake-compat.locked.rev}.tar.gz";
sha256 = lock.nodes.flake-compat.locked.narHash;
}
)
{ src = ./.; }
).defaultNix

View file

@ -1,5 +1,20 @@
{
"nodes": {
"flake-compat": {
"locked": {
"lastModified": 1696426674,
"narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=",
"ref": "refs/heads/master",
"rev": "0f9255e01c2351cc7d116c072cb317785dd33b33",
"revCount": 57,
"type": "git",
"url": "ssh://git@git.lix.systems/lix-project/flake-compat"
},
"original": {
"type": "git",
"url": "ssh://git@git.lix.systems/lix-project/flake-compat"
}
},
"flake-utils": {
"inputs": {
"systems": "systems"
@ -52,6 +67,7 @@
},
"root": {
"inputs": {
"flake-compat": "flake-compat",
"flake-utils": "flake-utils",
"lix": "lix",
"nixpkgs": "nixpkgs"

View file

@ -6,8 +6,9 @@
flake = false;
};
inputs.flake-utils.url = "github:numtide/flake-utils";
inputs.flake-compat.url = "git+ssh://git@git.lix.systems/lix-project/flake-compat";
outputs = { self, nixpkgs, lix, flake-utils }: {
outputs = { self, nixpkgs, lix, flake-utils, ... }: {
nixosModules.default = import ./module.nix { inherit lix; };
overlays.default = import ./overlay.nix { inherit lix; };
} // flake-utils.lib.eachDefaultSystem (system: