[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: determining the root revision of the "latest" tag

From: Hari Kodungallur <hkodungallur_at_gmail.com>
Date: 2007-12-14 03:19:30 CET

On Dec 13, 2007 4:00 PM, Ken Liu <ken.liu@gmail.com> wrote:

> Hi all -
> Is there any way to programmatically determine the root revision number of
> the newest (most recently created) tag (from the trunk)? Right now I am
> doing it manually, by first figuring out which is the latest tag and then
> looking at its log to find the earliest revision number. It would be nice
> if there was some way I could create a moving cvs-style tag to keep track of
> the latest tag baseline in the trunk.
>
> I would like to programatically generate a changelog of all commits on the
> trunk since the last tag was created (for the purpose of creating release
> notes).
>
>
As far as I know, svn itself does not provide a way to do this. You can
write scripts to achieve the same. You can also achieve this by following
some sort of standard for naming the tags.

- Placing the commands you execute manually, as explained above, is one
option.
- Or you could also have the post commit hook look for what is being copied
and if the copy is from trunk to a tag, then write the version number to a
shared directory.
- Or write a wrapper script for creating the tag. The script could
potentially move the current "latest" tag to "latest_<timestamp>" and then
create a new "latest" tag. [Obviously, everyone should use the script to
create the tags]

In short given that svn does not have direct support for what you are doing,
you can make subtle changes your process or write scripts to achieve the
same.

HTH,
-Hari
Received on Fri Dec 14 03:20:05 2007

This is an archived mail posted to the Subversion Users mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.