diff --git a/flake.lock b/flake.lock index 2d5307b..5b113e8 100644 --- a/flake.lock +++ b/flake.lock @@ -20,11 +20,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1734119587, - "narHash": "sha256-AKU6qqskl0yf2+JdRdD0cfxX4b9x3KKV5RqA6wijmPM=", + "lastModified": 1734649271, + "narHash": "sha256-4EVBRhOjMDuGtMaofAIqzJbg4Ql7Ai0PSeuVZTHjyKQ=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "3566ab7246670a43abd2ffa913cc62dad9cdf7d5", + "rev": "d70bd19e0a38ad4790d3913bf08fcbfc9eeca507", "type": "github" }, "original": { diff --git a/flake.nix b/flake.nix index 39785ac..460b662 100644 --- a/flake.nix +++ b/flake.nix @@ -37,14 +37,16 @@ ''; }; in { - packages = { - fantomas = dotnetTool "fantomas" (builtins.fromJSON (builtins.readFile ./.config/dotnet-tools.json)).tools.fantomas.version (builtins.head (builtins.filter (elem: elem.pname == "fantomas") ((import ./nix/deps.nix) {fetchNuGet = x: x;}))).hash; + packages = let + deps = builtins.fromJSON (builtins.readFile ./nix/deps.json); + in { + fantomas = dotnetTool "fantomas" (builtins.fromJSON (builtins.readFile ./.config/dotnet-tools.json)).tools.fantomas.version (builtins.head (builtins.filter (elem: elem.pname == "fantomas") deps)).hash; default = pkgs.buildDotnetModule { pname = pname; version = version; src = ./.; projectFile = projectFile; - nugetDeps = ./nix/deps.nix; # `nix build .#default.passthru.fetch-deps && ./result` and put the result here + nugetDeps = ./nix/deps.json; # `nix build .#default.fetch-deps && ./result nix/deps.json` doCheck = true; dotnet-sdk = dotnet-sdk; dotnet-runtime = dotnet-runtime; diff --git a/nix/deps.json b/nix/deps.json new file mode 100644 index 0000000..dd3c0c0 --- /dev/null +++ b/nix/deps.json @@ -0,0 +1,7 @@ +[ + { + "pname": "fantomas", + "version": "6.3.16", + "hash": "sha256-4tRdYf+/Q1iedx+DDuIKVGlIWQdr6erM51VdKzZkhCs=" + } +] diff --git a/nix/deps.nix b/nix/deps.nix deleted file mode 100644 index 88daced..0000000 --- a/nix/deps.nix +++ /dev/null @@ -1,9 +0,0 @@ -# This file was automatically generated by passthru.fetch-deps. -# Please dont edit it manually, your changes might get overwritten! -{fetchNuGet}: [ - (fetchNuGet { - pname = "fantomas"; - version = "6.3.16"; - hash = "sha256-4tRdYf+/Q1iedx+DDuIKVGlIWQdr6erM51VdKzZkhCs="; - }) -]