update-dotnet-lockfiles: add startWith flag

This allows you to resume after a failure by passing the name of the
first package you want to be fetched.
This commit is contained in:
David McFarland 2024-09-12 10:47:45 -03:00
parent 3a7d2b8bbf
commit 988b57fa74

View File

@ -9,6 +9,7 @@
infrastructure. Regular updates should be done through the individual packages
update scripts.
*/
{ startWith ? null }:
let
pkgs = import ../.. { config.allowAliases = false; };
@ -40,7 +41,8 @@ let
(lib.filter (p:
(builtins.tryEval p.outPath).success ||
builtins.trace "warning: skipping ${p.name} because it failed to evaluate" false)
(packagesWith (p: p ? fetch-deps) pkgs));
((pkgs: (lib.drop (lib.lists.findFirstIndex (p: p.name == startWith) 0 pkgs) pkgs))
(packagesWith (p: p ? fetch-deps) pkgs)));
helpText = ''
Please run: