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

Confused about "ident" filter

From
Peter Karlsson <peter@softwolves.pp.se>
Date
Apr 17, 2008, 07:15 UTC
Message-ID
<Pine.LNX.4.64.0804170812230.7970@ds9.cixit.se>
Hi!

While convincing my employer to convert to Git, I've ran into the old RCS keyword expansion problem again. They have files that they need to export to a customer, without revision history, but they need to embed an identifier that can tell them which version of the file it was.

So, I tried setting up a .gitattributes file:
   * ident
and a simple test perl script that would show me the ident:
   #!/usr/bin/perl
   print 'I am $Id$', "\n";

but I cannot figure out how to get it to actually expand the $Id$. I tried doing "git checkout test.perl", I tried "git clone" to get a new copy of the repository, but still it showed only "$Id$".

I found that "git archive" *does* work.
-- 
\\// Peter - http://www.softwolves.pp.se/
Next: Paolo Bonzini
Message 1 of 3 in “Confused about "ident" filter”
  1. Peter KarlssonApr 17, 2008
  2. Paolo BonziniApr 17, 2008
  3. Jakub NarebskiApr 19, 2008

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.