git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH 2/3] stripspace: respect repository config

From
Junio C Hamano <gitster@pobox.com>
Date
Nov 22, 2016, 19:10 UTC
Message-ID
<xmqqzikrpbz2.fsf@gitster.mtv.corp.google.com>
In-Reply-To
<xmqqshqjqw3z.fsf@gitster.mtv.corp.google.com>
Junio C Hamano <gitster@pobox.com> writes:
Show 5 quoted lines
> I think we want to audit the ones without RUN_SETUP* in the command
> table in order to hunt for regression aka "a fix revealed a bug that
> was covered by .git/config accidentally getting read when run from
> the top-level of the working tree", though. We may find unreported
> breakages that we may have to fix.

So I took a brief look at the "PROGRAM_OBJS += ..." in the Makefile for non-builtin commands, and commands[] array in git.c for builtin commands to see how bad it looks.

Archive & Upload-archive:

"cd Documentation && git archive --remote=origin" immediately hits "BUG: setup_git_env called without repository" if your Git is built with b1ef400eec ("setup_git_env: avoid blind fall-back to ".git"", 2016-10-20), which will not be part of the upcoming release. And 'origin' will probably not be understood from the local config.

I think we can do the "gently" thing there, as we may be retrieving a remote archive outside a local repository. We'd need to tweak "output" with prefix to compensate for the case in which the command is run from a subdirectory, and probably we need to futz with the setup_prefix parameter to write_archive(), as a local caller now will know if we are in nongit situation.

On the upload-archive side that serves "--remote" request, there is enter_repo() so we should be covered OK.

Mailinfo:

We may want a "gently" thing there to pick up local configuration. i18n.commitencoding and mailinfo.scissors in local repository would be ignored otherwise.

Splitspace:
Dscho fixed this one.
Verify-pack:

This calls git_config() but these days farms out its operation to "index-pack", so we should be OK. We may even want to lose the call to git_config() which does not affect anything.

Previous: Junio C HamanoNext: Jeff King
Message 6 of 40 in “Fix problems with rebase -i when core.commentchar is defined”
  1. 0/3 Fix problems with rebase -i when core.commentchar is definedJohannes Schindelin, Nov 21, 2016
  2. 2/3 stripspace: respect repository configJohannes Schindelin, Nov 21, 2016
  3. Duy NguyenNov 22, 2016
  4. Johannes SchindelinNov 22, 2016
  5. Junio C HamanoNov 22, 2016
  6. Junio C HamanoNov 22, 2016
  7. Jeff KingNov 22, 2016
  8. Junio C HamanoNov 22, 2016
  9. Jeff KingNov 22, 2016
  10. Junio C HamanoNov 22, 2016
  11. Jeff KingNov 22, 2016
  12. Junio C HamanoNov 22, 2016
  13. Jeff KingNov 23, 2016
  14. Jeff KingNov 22, 2016
  15. 1/3 rebase -i: identify problems with core.commentcharJohannes Schindelin, Nov 21, 2016
  16. Junio C HamanoNov 21, 2016
  17. Junio C HamanoNov 21, 2016
  18. 1/3 rebase -i: highlight problems with core.commentcharJunio C Hamano, Nov 21, 2016
  19. 2/3 stripspace: respect repository configJunio C Hamano, Nov 21, 2016
  20. Junio C HamanoNov 21, 2016
  21. Johannes SchindelinNov 22, 2016
  22. 3/3 rebase -i: handle core.commentChar=autoJunio C Hamano, Nov 21, 2016
  23. Junio C HamanoNov 21, 2016
  24. Junio C HamanoNov 21, 2016
  25. Johannes SchindelinNov 22, 2016
  26. Junio C HamanoNov 22, 2016
  27. Johannes SchindelinNov 23, 2016
  28. Jeff KingNov 21, 2016
  29. Junio C HamanoNov 21, 2016
  30. Jeff KingNov 21, 2016
  31. Johannes SchindelinNov 22, 2016
  32. 3/3 rebase -i: handle core.commentChar=autoJohannes Schindelin, Nov 21, 2016
  33. Johannes SixtNov 21, 2016
  34. Junio C HamanoNov 21, 2016
  35. Johannes SixtNov 21, 2016
  36. Junio C HamanoNov 21, 2016
  37. Johannes SixtNov 21, 2016
  38. Johannes SchindelinNov 22, 2016
  39. Duy NguyenNov 22, 2016
  40. Jacob KellerNov 21, 2016

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.