You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Ben Reser <be...@reser.org> on 2004/10/13 16:58:47 UTC

Re: Naughty commits to tags

On Wed, Oct 13, 2004 at 10:56:07PM +1000, Daniel Patterson wrote:
> (there are some naughty looking tag modifications in there ;-) )

We modify our release tags to match the tarball.  This is the result of
juggling a couple of issues with respect to how our releases are cut.

* Releaseas are exported against a particular revision.  

* We test the tarball to see if everything is good before we call it a
final release.  If we were to modify the branches svn_version.h before
cutting the release and then decide that the release was bad and needed
another change then there would be multiple paths in the repo which you
could check out and identify themselves as a given release.  

* Applying the svn_version.h changes to the branch and then committing
also only works if you can guarantee that no other commits happen on the
branch between when you commit the last change going in the rev (your
export rev), the change to svn_version.h, the tag revision, and the
bumping of svn_version.h to the dev version of next release number.

That said I believe there is another way to do this... That hadn't
occured to me until just now.  

svn up -r releaserev
#modify svn_version.h to the tag markings
svn cp -m "Tagging 1.0.x release with svn_version.h matching tarball" \
  . https://svn.collab.net/repos/svn/tags/1.0.x

That should copy the files from the releaserev and apply my one local
change to the tag.  I'll give it a try today when I cut the 1.0.9
release.

It should avoid the problems above and solve the one problem of
modifying the tag.  There is one rev where if you look at the tag it
will be marked as the dev version of the version the tag represents, as
opposed to the release version.

-- 
Ben Reser <be...@reser.org>
http://ben.reser.org

"Conscience is the inner voice which warns us somebody may be looking."
- H.L. Mencken

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

svnversion doc (was Naughty commits to tags)

Posted by Simon Large <sl...@blazepoint.co.uk>.
"Ben Reser" wrote
> On Thu, Oct 14, 2004 at 10:45:09AM +0100, Simon Large wrote:
> > SubWCRev (available on the TSVN site) will scan your WC for the
highest
> > revision number, so it doesn't rely on a updating a file every
commit.
> > It's a command line tool, but it only works on the Windows platform,
so
> > probably won't be much help here.
> >
> > It would be even better if this sort of tool were provided directly
by
> > subversion so it can be used on many platforms. Sadly I don't have
> > enough knowledge to do that myself.
>
> You mean like svnversion that's included in our standard set of tools?

I mean exactly like that.

As an aside, svnversion is not documented at all in the SVN book, aside
from a passing reference.

svndumpfilter is documented, but would benefit from an entry in chapter
9.

Simon



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: Naughty commits to tags

Posted by Ben Reser <be...@reser.org>.
On Thu, Oct 14, 2004 at 10:45:09AM +0100, Simon Large wrote:
> SubWCRev (available on the TSVN site) will scan your WC for the highest
> revision number, so it doesn't rely on a updating a file every commit.
> It's a command line tool, but it only works on the Windows platform, so
> probably won't be much help here.
> 
> It would be even better if this sort of tool were provided directly by
> subversion so it can be used on many platforms. Sadly I don't have
> enough knowledge to do that myself.

You mean like svnversion that's included in our standard set of tools?

-- 
Ben Reser <be...@reser.org>
http://ben.reser.org

"Conscience is the inner voice which warns us somebody may be looking."
- H.L. Mencken

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: Naughty commits to tags

Posted by Daniel Patterson <da...@danpat.net>.
Simon Large wrote:

>SubWCRev (available on the TSVN site) will scan your WC for the highest
>revision number, so it doesn't rely on a updating a file every commit.
>It's a command line tool, but it only works on the Windows platform, so
>probably won't be much help here.
>  
>

On most Unix platforms, you could do:

  svn info -R | grep Revision | awk '{print $2}' | sort -n | tail -1

daniel

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: Naughty commits to tags

Posted by Simon Large <sl...@blazepoint.co.uk>.
"Daniel Patterson" wrote:
> That's a good thing to avoid.  Has anyone considered calculating the
> version number
> based on a "$HeadURL$" keyword? (Work out if it's trunk or a tag at
> build time)
>
> I can't think of a good way to say "Subversion DEV build from Trunk at
> Rev 11355"
>  without having a new keyword like "$WCRev$" that gets updated on
every
> "svn up" ($LastChangedRevision$ doesn't quite do it, unless you update
> the file on every commit).

SubWCRev (available on the TSVN site) will scan your WC for the highest
revision number, so it doesn't rely on a updating a file every commit.
It's a command line tool, but it only works on the Windows platform, so
probably won't be much help here.

It would be even better if this sort of tool were provided directly by
subversion so it can be used on many platforms. Sadly I don't have
enough knowledge to do that myself.

No generic tool will be able to tell if something is on trunk, branch or
tag, except by trying to interpreting the meaning of the URL - fine if
you know they will always be called trunk/branches/tags, but that scheme
is not mandatory. But maybe the build script could do it.

Simon



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: Naughty commits to tags

Posted by Daniel Patterson <da...@danpat.net>.
Ben Reser wrote:

>On Wed, Oct 13, 2004 at 10:56:07PM +1000, Daniel Patterson wrote:
>  
>
>>(there are some naughty looking tag modifications in there ;-) )
>>    
>>
>
>* Applying the svn_version.h changes to the branch and then committing
>also only works if you can guarantee that no other commits happen on the
>branch between when you commit the last change going in the rev (your
>export rev), the change to svn_version.h, the tag revision, and the
>bumping of svn_version.h to the dev version of next release number.
>
>  
>
That's a good thing to avoid.  Has anyone considered calculating the 
version number
based on a "$HeadURL$" keyword? (Work out if it's trunk or a tag at 
build time)

I can't think of a good way to say "Subversion DEV build from Trunk at 
Rev 11355"
 without having a new keyword like "$WCRev$" that gets updated on every 
"svn up" ($LastChangedRevision$ doesn't quite do it, unless you update 
the file on every commit).

daniel

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: Naughty commits to tags

Posted by Mark Benedetto King <mb...@lowlatency.com>.
On Wed, Oct 13, 2004 at 09:58:47AM -0700, Ben Reser wrote:
> On Wed, Oct 13, 2004 at 10:56:07PM +1000, Daniel Patterson wrote:
> > (there are some naughty looking tag modifications in there ;-) )
> 
> We modify our release tags to match the tarball.  This is the result of
> juggling a couple of issues with respect to how our releases are cut.
> 

I think he might have been talking about r6804 and the subsequent
coverup, revisions 6805 and 6806.

--ben


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org