diff --git a/flake.lock b/flake.lock index 6d399c5..3c605fc 100644 --- a/flake.lock +++ b/flake.lock @@ -15,23 +15,6 @@ "type": "github" } }, - "nix-extras": { - "flake": false, - "locked": { - "lastModified": 1574214871, - "narHash": "sha256-agE1aUir8UdqMJVyz2Xhe+jAR1AG1kmlF5mEHdHYmB4=", - "owner": "colehaus", - "repo": "nix-extras", - "rev": "f33ab8f70982073b08c67e0d4f6144d029f0441d", - "type": "github" - }, - "original": { - "owner": "colehaus", - "repo": "nix-extras", - "rev": "f33ab8f70982073b08c67e0d4f6144d029f0441d", - "type": "github" - } - }, "nixpkgs": { "locked": { "lastModified": 1603791972, @@ -67,7 +50,6 @@ "root": { "inputs": { "flake-utils": "flake-utils", - "nix-extras": "nix-extras", "nixpkgs": "nixpkgs", "resume-cli": "resume-cli" } diff --git a/flake.nix b/flake.nix index 44a076c..9596cfe 100644 --- a/flake.nix +++ b/flake.nix @@ -2,10 +2,6 @@ description = "CLI tool to easily setup a new resume"; inputs = { - nix-extras = { - url = "github:colehaus/nix-extras/f33ab8f70982073b08c67e0d4f6144d029f0441d"; - flake = false; - }; flake-utils.url = "github:numtide/flake-utils"; resume-cli = { url = "github:jsonresume/resume-cli/7fb40dab8ca6aa519bd3c4ac2729b9fa4256cdcb"; @@ -17,19 +13,17 @@ nixpkgs.url = "nixpkgs/20.09"; }; - outputs = { self, nixpkgs, resume-cli, nix-extras, flake-utils }: + outputs = { self, nixpkgs, resume-cli, flake-utils }: let forPkgs = pkgs: let dbg = pkgs.lib.traceVal; - callNode2nix = import "${nix-extras}/callNode2nix.nix"; - node2nix = callNode2nix { inherit pkgs; name = "resume-cli"; package = "${resume-cli}/package.json"; packageLock = "${resume-cli}/package-lock.json"; }; nixifiedSrc = - with pkgs; - (runCommandLocal "node2nix-merge" { } '' + (pkgs.runCommandLocal "node2nix-merge" { buildInputs = [ pkgs.nodePackages.node2nix ]; } '' mkdir -p $out cp -r ${resume-cli}/* $out - cp -rf ${node2nix}/* $out/ + cd $out + node2nix --input package.json --lock package-lock.json '' ); nodePackages = pkgs.callPackage "${nixifiedSrc}" { inherit pkgs; system = pkgs.system; };