mirror of
https://github.com/NotAShelf/nyxexprs.git
synced 2025-10-01 14:33:29 +00:00
nix: simplify flake-compat exp
This commit is contained in:
parent
3d0975e08c
commit
309c11400b
1 changed files with 10 additions and 20 deletions
30
default.nix
30
default.nix
|
@ -1,21 +1,11 @@
|
|||
(
|
||||
import
|
||||
(
|
||||
let
|
||||
lock = builtins.fromJSON (builtins.readFile ./flake.lock);
|
||||
nodeName = lock.nodes.root.inputs.flake-compat;
|
||||
in
|
||||
fetchTarball {
|
||||
url =
|
||||
lock.nodes.${
|
||||
nodeName
|
||||
}.locked.url
|
||||
or "https://github.com/edolstra/flake-compat/archive/${
|
||||
lock.nodes.${nodeName}.locked.rev
|
||||
}.tar.gz";
|
||||
sha256 = lock.nodes.${nodeName}.locked.narHash;
|
||||
}
|
||||
)
|
||||
{src = ./.;}
|
||||
)
|
||||
(import (
|
||||
let
|
||||
lock = builtins.fromJSON (builtins.readFile ../flake.lock);
|
||||
flakeCompatNode = lock.nodes.${lock.nodes.root.inputs.flake-compat}.locked;
|
||||
in
|
||||
fetchTarball {
|
||||
url = "https://github.com/${flakeCompatNode.owner}/${flakeCompatNode.repo}/archive/${flakeCompatNode.rev}.tar.gz";
|
||||
sha256 = flakeCompatNode.narHash;
|
||||
}
|
||||
) {src = ./.;})
|
||||
.defaultNix
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue