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

Re: [PATCH v2] Custom compression levels for objects and packs

From
DHDana How <danahow@gmail.com>
Date
May 9, 2007, 06:46 UTC
Message-ID
<56b7f5510705082346m32d3c48dj987fd9b0a6118c10@mail.gmail.com>
In-Reply-To
<alpine.LFD.0.99.0705082031370.24220@xanadu.home>
On 5/8/07, Nicolas Pitre <nico@cam.org> wrote:
Show 10 quoted lines
> On Tue, 8 May 2007, Dana How wrote:
> > On 5/8/07, Nicolas Pitre <nico@cam.org> wrote:
> > > On Tue, 8 May 2007, Junio C Hamano wrote:
> > > If we want the fallback logic to work, at some point we must remember if
> > > the current value is the default or if it is the result of an explicit
> > > config option.
> > I can leave as-is, or use a magic value like -99 and
> > depend on it not colliding with values in zlib.h.
> And where would you set those variables to a sensible default in the
> absence of any config option?

This is why I used the _seen variables, but they are not necessary -- see 3rd option below.

Unfortunately we agreed a day or two ago to use a config rule like used_value = isset(var1) ? var1 : isset(var2) ? var2 : DEFAULT. This doesn't interact well with each variable being processed completely independently in git_config() and the callbacks it calls. The isset() value is "out-of-band"; either store it in the _seen variables, or some special value in used_value .

Which makes the most sense:
* Leave _seen as-is;
* Move pack.compression recognition into config.c which means
  the _seen variables would all be local to config.c;
* Use some special value, and if still present replace it with the default
  at the end of git_config() using extra code;
* Change the config rule to something simpler.

I like the 2nd and the 4th. You didn't like the 4th. Shall I change to the 2nd?

Thanks,
-- 
Dana L. How  danahow@gmail.com  +1 650 804 5991 cell
Previous: Nicolas PitreNext: Junio C Hamano
Message 6 of 23 in “Custom compression levels for objects and packs”
  1. Custom compression levels for objects and packsDana How, May 8, 2007
  2. Junio C HamanoMay 8, 2007
  3. Nicolas PitreMay 9, 2007
  4. Dana HowMay 9, 2007
  5. Nicolas PitreMay 9, 2007
  6. Dana HowMay 9, 2007
  7. Junio C HamanoMay 9, 2007
  8. Dana HowMay 9, 2007
  9. Nicolas PitreMay 9, 2007
  10. Dana HowMay 9, 2007
  11. Nicolas PitreMay 9, 2007
  12. Junio C HamanoMay 9, 2007
  13. Dana HowMay 9, 2007
  14. make "repack -f" imply "pack-objects --no-reuse-object"Nicolas Pitre, May 9, 2007
  15. deprecate the new loose object header formatNicolas Pitre, May 9, 2007
  16. Dana HowMay 9, 2007
  17. Nicolas PitreMay 9, 2007
  18. Dana HowMay 9, 2007
  19. Junio C HamanoMay 9, 2007
  20. Dana HowMay 9, 2007
  21. Petr BaudisMay 9, 2007
  22. Theodore TsoMay 9, 2007
  23. Dana HowMay 9, 2007

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.