Re: [PATCH v3 2/4] run-command: extract clear_local_repo_env helper
- From
Derrick Stolee <stolee@gmail.com>
- Date
- Mar 2, 2026, 18:37 UTC
- Message-ID
- <17dea0d7-b67c-460a-a08a-1f3a2986c524@gmail.com>
- In-Reply-To
- <20260302180324.GC28275@coredump.intra.peff.net>
On 3/2/2026 1:03 PM, Jeff King wrote:
Show 20 quoted lines
> So what about squashing in: > > diff --git a/run-command.h b/run-command.h > index 76b29d4832..882caeccc8 100644 > --- a/run-command.h > +++ b/run-command.h > @@ -518,11 +518,9 @@ void clear_local_repo_env(struct strvec *env); > > /** > * Convenience function which prepares env for a command to be run in a > - * new repo. This adds all GIT_* environment variables to env with the > - * exception of GIT_CONFIG_PARAMETERS and GIT_CONFIG_COUNT (which cause the > - * corresponding environment variables to be unset in the subprocess) and adds > - * an environment variable pointing to new_git_dir. See local_repo_env in > - * environment.h for more information. > + * new repo. This removes variables pointing to the local repository (using > + * clear_local_repo_env() above), and adds an environment variable pointing to > + * new_git_dir. > */ > void prepare_other_repo_env(struct strvec *env, const char *new_git_dir);
I'm happy to squash this in.
Perhaps Junio can do it if we don't need other changes to v3. (I haven't read the rest of the feedback.)
Thanks, -Stolee