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

Re: Stamp Git commit id into file during build process

From
Sverre Rabbelier <srabbelier@gmail.com>
Date
Jan 16, 2010, 19:17 UTC
Message-ID
<fabb9a1e1001161117t6d572024yc5598be1b32ffcde@mail.gmail.com>
In-Reply-To
<40aa078e1001161114w5a65bebbhaf43317634899925@mail.gmail.com>
Heya,
On Sat, Jan 16, 2010 at 20:14, Erik Faye-Lund <kusmabite@googlemail.com> wrote:
> I think you are looking for "git rev-parse HEAD". This outputs the
> hash of HEAD as a single line on stdout. Or even better, you can use
> the "git describe"-tool, which gives a nice and short description of
> the commit relative to the most recent commit.
It would be better to have a look at gitattributes [0] instead.
[0] http://www.kernel.org/pub/software/scm/git/docs/gitattributes.html#_tt_ident_tt
-- 
Cheers,

Sverre Rabbelier
Previous: Erik Faye-LundNext: Erik Faye-Lund
Message 4 of 10 in “Stamp Git commit id into file during build process”
  1. Paul RichardsJan 16, 2010
  2. Erik Faye-LundJan 16, 2010
  3. Erik Faye-LundJan 16, 2010
  4. Sverre RabbelierJan 16, 2010
  5. Erik Faye-LundJan 16, 2010
  6. Sverre RabbelierJan 16, 2010
  7. Jakub NarebskiJan 16, 2010
  8. Paul RichardsJan 16, 2010
  9. Shawn O. PearceJan 16, 2010
  10. Jakub NarebskiJan 16, 2010

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.