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

Re: [PATCH 2/2] introduce "preciousObjects" repository extension

From
Jeff King <peff@peff.net>
Date
Jun 24, 2015, 07:55 UTC
Message-ID
<20150624075514.GB827@peff.net>
In-Reply-To
<1435095074.28466.74.camel@twopensource.com>
On Tue, Jun 23, 2015 at 05:31:14PM -0400, David Turner wrote:
Show 7 quoted lines
> On Tue, 2015-06-23 at 06:54 -0400, Jeff King wrote:
> > +	mkconfig 1 preciousObjects >.git/config &&
> 
> nit: I think it's better to use git config rather than manually writing
> config files.  git config is more future-proof if we up switching config
> backends; it's also more composable with other configs (making this test
> easier to copy and manipulate), and more explicit.

I would have preferred that, but it makes the tests very fragile. You are depending on "git config" running even when the current directory is not a valid git repo (and we walk up to the surround git.git directory and change the config there!).

I guess we could use "git config -f .git/config", though that is partially defeating the purpose of your suggestion.

I dunno. I kind of figured we would cross that bridge if and when we come to it. I imagine you are pretty sensitive to it, though, having just waded through all the tests that assume various things about .git/refs. :)

-Peff
Previous: David TurnerNext: Jeff King
Message 11 of 13 in “bumping repository format version”
  1. 0/2 bumping repository format versionJeff King, Jun 23, 2015
  2. 1/2 introduce "extensions" form of core.repositoryformatversionJeff King, Jun 23, 2015
  3. 2/2 introduce "preciousObjects" repository extensionJeff King, Jun 23, 2015
  4. Duy NguyenJun 23, 2015
  5. Jeff KingJun 23, 2015
  6. Junio C HamanoJun 23, 2015
  7. Jeff KingJun 24, 2015
  8. Junio C HamanoJun 24, 2015
  9. Jeff KingJun 25, 2015
  10. David TurnerJun 23, 2015
  11. Jeff KingJun 24, 2015
  12. Jeff KingJun 24, 2015
  13. Duy NguyenJun 24, 2015

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.