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

Re: Weird shallow-tree conversion state, and branches of shallow trees

From
Julian Phillips <julian@quantumfyre.co.uk>
Date
Apr 16, 2007, 15:17 UTC
Message-ID
<Pine.LNX.4.64.0704161612120.5400@reaper.quantumfyre.co.uk>
In-Reply-To
<200704161010.47059.andyparkins@gmail.com>
On Mon, 16 Apr 2007, Andy Parkins wrote:
Show 30 quoted lines
> On Monday 2007 April 16 01:11, Bill Lear wrote:
>
>> Not that Linus needs any back-up from me, but I second this, very
>> strongly.  Decorating source code with release information is a proper
>> function of release management tools, not the SCM system.  We had a
>> similar argument in our company about this, sparked by a criticism of
>> git for not having keyword (version number) substitution, and I argued
>> that having such substitution functions in the SCM was out-of-place
>> and a crutch for weak release procedures.  It's easy with a proper
>> make system to put whatever information you want from the SCM into the
>> release product.
>
> I'm not disagreeing with any of this - there are certainly cases when
> expansion is completely the wrong tool.  That doesn't mean there are no cases
> where it would be useful.
>
> The case I keep banging on about is that where nothing is made and this is not
> a release.  I don't want to make a release, I just want to print out the
> current version of a file and have something that appears on the printout
> that would allow me to identify what version of the file that printout was
> from.  Are you seriously suggesting I should run release scripts just for
> that?
>
> It's not something you want - fine - not a problem for me that you wouldn't
> use it.  The thing that is bothering me is that everyone keeps waving their
> hands while chanting "keyword expansion evil", while not giving an example of
> what problem it causes.  By this I mean "problem for the end user",
> not "problem in writing the support" - if it's impractical to implement then
> that's fine, say that.
>

What I don't understand is why the people who want keyword expansion don't simply write a little wrapper script, a keyworded git as it were (you could even call it gitk for maximum confusion :P).

In the script you simply:
1) collapse all keywords
2) call appropriate git function
3) expand keywords again

wouldn't that do what people want without having to change the git code at all? You could probably even get it into contrib ..

(In the case of gentoo, you could even change the ebuild so that the real git is installed as raw_git or something, and the wrapper is installed as git - though personally I wouldn't want to do that)

-- 
Julian

  ---
You may get an opportunity for advancement today.  Watch it!
Previous: Andy ParkinsNext: Robin H. Johnson
Message 14 of 34 in “Weird shallow-tree conversion state, and branches of shallow trees”
  1. Robin H. JohnsonApr 12, 2007
  2. Johannes SchindelinApr 14, 2007
  3. Robin H. JohnsonApr 15, 2007
  4. David LangApr 15, 2007
  5. Robin H. JohnsonApr 15, 2007
  6. Shawn O. PearceApr 15, 2007
  7. Nguyen Thai Ngoc DuyApr 15, 2007
  8. Jakub NarebskiApr 15, 2007
  9. Linus TorvaldsApr 15, 2007
  10. Andy ParkinsApr 15, 2007
  11. Linus TorvaldsApr 15, 2007
  12. Bill LearApr 16, 2007
  13. Andy ParkinsApr 16, 2007
  14. Julian PhillipsApr 16, 2007
  15. Robin H. JohnsonApr 16, 2007
  16. Theodore TsoApr 16, 2007
  17. Nguyen Thai Ngoc DuyApr 16, 2007
  18. Linus TorvaldsApr 16, 2007
  19. Nguyen Thai Ngoc DuyApr 16, 2007
  20. Robin H. JohnsonApr 16, 2007
  21. Linus TorvaldsApr 16, 2007
  22. Daniel BarkalowApr 17, 2007
  23. Linus TorvaldsApr 16, 2007
  24. Andy ParkinsApr 16, 2007
  25. Sven VerdoolaegeApr 16, 2007
  26. Linus TorvaldsApr 16, 2007
  27. David LangApr 16, 2007
  28. David LangApr 17, 2007
  29. Andy ParkinsApr 17, 2007
  30. Junio C HamanoApr 16, 2007
  31. Andy ParkinsApr 16, 2007
  32. Junio C HamanoApr 17, 2007
  33. Andy ParkinsApr 17, 2007
  34. Robin H. JohnsonApr 15, 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.