nix-prefetch-git: disable maintenance mode via environment variables#525255
Conversation
The commit 011471c ("fetchgit: disable git maintenance") disabled git's maintenance mode, but that does not affect git repositories with submodules. Switch to using the GIT_CONFIG_* environment variables. This is done in a way to make the approach more generic, but also kinda not the best ("insane") so that it works with any future change, even with `impureEnvVars`. Maybe `git -c maintenance.auto=false` can work but I cannot figure out how to use that here. I would prefer disabling maintenance mode in Git's derivation itself but did not find any build-time knob to toggle that.
7f21e88 to
88cfc54
Compare
|
I realized that I overlooked the commit message about making |
|
|
|
Huh, 2 packages were not automatically detected on |
|
|
philiptaron
left a comment
There was a problem hiding this comment.
Sure. Looking to @me-and to ✅ also before merge
|
|
I'll try to review before the end of the weekend. I'm slightly surprised I didn't hit this problem when I made this fix, as the test repo I was using absolutely had submodules! Without yet having looked at the code, a possible alternative to |
I've noticed this inconsistency too. In #524670, we're trying to bump the version for packages of the COSMIC DE and only one package (
I don't have a strong opinion on this. I'm happy to refactor this PR if that's what you want. |
me-and
left a comment
There was a problem hiding this comment.
LGTM! I'd honestly expected something much more horrendous before I went looking at the code.
Thank you!
NixOS/nixpkgs#524430 only disabled maintenance.auto in the top-level repo's local config; submodule clones spawned by postCheckout still raced. NixOS/nixpkgs#525255 switches to env vars that propagate into submodule subprocesses. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
|
Could someone with commit access merge this PR? |
|
Successfully created backport PR for |
The commit 011471c ("fetchgit: disable git maintenance") disabled
git's maintenance mode, but that does not affect git repositories with
submodules.
Switch to using the GIT_CONFIG_* environment variables. This is done in
a way to make the approach more generic, but also kinda not the best
("insane") so that it works with any future change, even with
impureEnvVars.Maybe
git -c maintenance.auto=falsecan work but I cannot figure outhow to use that here. I would prefer disabling maintenance mode in Git's
derivation itself but did not find any build-time knob to toggle that.
Things done
passthru.tests.nixpkgs-reviewon this PR. See nixpkgs-review usage../result/bin/.