From: Christian Couder <christian.couder@gmail.com>
To: Delanoe Eric <e.delanoe@gea.fr>
Cc: "git@vger.kernel.org" <git@vger.kernel.org>
Subject: Re: Could GIT manage revision headers embedded in code ?
Date: Tue, 2 May 2017 14:11:16 +0200 [thread overview]
Message-ID: <CAP8UFD0NrTyGYgHeEOWpUH5v0ejKvcKu+Mzd8_scYbvzL4b4zg@mail.gmail.com> (raw)
In-Reply-To: <135C7A92C7D64E488B830ADC2970C70132AE6407@SVGEA-EMAIL.gea.fr>
Hi,
On Tue, May 2, 2017 at 1:48 PM, Delanoe Eric <e.delanoe@gea.fr> wrote:
> Hello,
>
> We need a great deal of traceability for our source, made of many scripts in interpreted languages, spread in many "independent" modules, as far as can be ;-).
> In particular, somebody troubleshooting a script in production should be able to know exactly the revision or commit ID (or tag label) of a given file, and its location in the GIT source directory tree.
>
> Our old CVS... let's say it was its only advantage... was doing this with keywords embedded in code comments: $Header$, $Id$, $Rev$, $File$ etc... When a file was committed, its $Header$ keyword was expanded into a rich piece of "version" information like '' $Header: /cvsstore/SourcesOracle/Install/COMMUN/CST.sql,v 1.69.2.10 2017/04/14 09:38:48 edelanoe $".
>
> Could this kind of "keyword expansion" feature be added into GIT ?
You can already do it with "smudge" and "clean" filters. Look for
"Keyword Expansion" in:
https://git-scm.com/book/en/v2/Customizing-Git-Git-Attributes
next prev parent reply other threads:[~2017-05-02 12:11 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-05-02 11:48 Could GIT manage revision headers embedded in code ? Delanoe Eric
2017-05-02 12:11 ` Christian Couder [this message]
2017-05-02 13:33 ` Delanoe Eric
2017-05-02 15:54 ` Johannes Schindelin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CAP8UFD0NrTyGYgHeEOWpUH5v0ejKvcKu+Mzd8_scYbvzL4b4zg@mail.gmail.com \
--to=christian.couder@gmail.com \
--cc=e.delanoe@gea.fr \
--cc=git@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).