Reputation: 21
We have a large project which consists of a single build job (Maven, via a pom.xml, with multiple child folders etc). Developers have given us three different revision numbers, and would like us to create a single tag that we can feed the (Hudson) build job.
Example:
/ -- at rev X
/project1 -- at rev Y
/project2 -- at rev Z
I was able to create this tag by syncing the entire branch to rev X, then "cd project1" and sync to rev Y, then "cd ..\project2" and sync to rev Z, then "cd .." and create the tag from the current directory.
We would like to be able to create the tag from a single command line (and, without having to sync any files to our local workstation, by using URLs). Is this possible? We have tried several variants but none seemed to work.
Thanks,
Ken
Upvotes: 2
Views: 3059
Reputation: 2752
I see two approaches to meet your requirement
I will treat your "/" as "trunk" btw. as it wouldnt make sense for creating tags otherwise ;)
copy from revision approach
advantages
disadvantage
mark as stable approach
do this step once in your trunk:
add these two lines:
svn propset svn:externals -F externals .
Whoever checks out your main app will now get the latest versions of your projects when they were ready for release.
development teams for the projects do these steps whenever a new release is ready. They can decide to use the revision number or simply tag HEAD when they are ready:
svn copy http://myrepos/project1/@y http://myrepos/1.0/project1/tags/to-be-released
on release/tag-day:
You can use a revision number too. Problem here is that your application layout indicates that project1 and 2 reside inside your main application "/". If that is not the case tagging and using fixed taggs for release-integration can be verry smooth. ("/" would get sub-tagged too)
real world example:
svn propget svn:externals http://svn.silverstripe.com/open/phpinstaller/tags/2.4.2/
advantages
disadvantages
Tags are just "symlinks" to revision so both scenarios use the same principle. Tagging feels more explicit though. This whole scenario is not a 1:1 copy-and-it-works suggestion but more of a generic model.
Upvotes: 2
Reputation: 1436
svnmerge may help you in this case.
svnmerge.py wiki says "Specific support for release branches through cherry-picking: name and merge single revisions or revision ranges."
I have not checked it myself, do give it a try.
Upvotes: -1
Reputation: 224079
You can always do svn copy
manually to copy stuff over to a newly created folder under tags
. If you want, you can also make up a simple script doing this given three revision numbers.
If the copy targets are paths into your working copy (rather than URLs into the repository), you can later commit all of it in one step.
Upvotes: 0