Re: git-describe recognize modified files
Andreas Krey <a.krey@gmx.de> writes:
Show 23 quoted lines
> On Tue, 19 Jan 2010 11:35:41 +0000, Johannes Schindelin wrote:
> ...
> > > To solve this issue, in addition to git-describe, my do_version script
> > > also run git-status, and if there are "modified:" files then it
> > > concatenates the string "+dirty" to output of git-describe.
> >
> > The problem is that this does not describe the exact version you used very
> > well.
>
> I (and probably the original poster) don't care that much; for me the
> important information is that the binary (or whatever) was not built
> from the exact committed state. Thus the question is whether the
> second two lines of
>
> BUILDINFO=git-`git describe --abbrev=16 --always HEAD 2>/dev/null`
> git update-index -q --refresh
> test -z "`git diff-index --name-only HEAD --`" || BUILDINFO="$BUILDINFO.dirty"
>
> (after GIT-VERSION-GEN) are worth to be integrated into git-describe?
>
> (And whether it should also say '.dirty'
> when there are untracked files present.
> Or either for submodules.)
FYI it is integrated in git-describe since
9f67d2e (Teach "git describe" --dirty option, 2009-10-21)
by Jean Privat (it should be present in 1.6.6, IIRC).
--
Jakub Narebski
Poland
ShadeHawk on #git