Hi Bob,
> -----Original Message-----
> From: Bob Archer [mailto:Bob.Archer_at_amsi.com]
> Sent: 04 December 2013 15:22
>
> > Hi Folks,
> >
> > I would like to include the svn revision number in my
> > project's version info but I am confused by the results
> > of svnversion. I want the version number of a tagged
> > tree to always be the same (i.e. the last commit to the
> > tag) but if the tag is to be rebuilt using a fresh
> > checkout some time later `svnversion` seems to report
> > the HEAD revision. So I looked at `svnversion -c` but
> > this always seems to give me a range e.g. `2:1476`, even
> > directly after an update.
> >
> > I have read the red book but it is quite vague about the
> > -c option. Why is `-c`
> > always giving me a range?
> >
> > Many thanks,
> >
> > ~ mark c
>
> If you are on windows you can use SubWCRev which is
> distributed with tortoiseSVN. It is designed to do what you want.
>
> http://tortoisesvn.net/docs/release/TortoiseSVN_en/tsvn-subwcrev.html
>
> BOb
Thanks very much, I do not know how I have managed to not notice that since we have been using TortoiseSVN for years...
Interestingly, the sample keyword file does not seem to work properly:
char *Revision = "$WCREV$"; >> char *Revision = "1755";
char *Revision16 = "$WCREV&0xFF$"; >> char *Revision16 = "$WCREV&0xFF$";
...but that is for another list.
~ mark c
Received on 2013-12-05 10:03:05 CET