开发者

svn build and release

This is the scenario

I use SVN as my code repository. I have a separate Windows build machine that uses ant scripts to generate the final "jar" file. The automated build script checks out the latest version of the code a开发者_StackOverflownd does the build. Once build is done - a tag is created (in the format YYYYMMDD-build 1.01.jar). We also store the build file(the final jar) in subversion. Any properties files, configuration files, or database scripts(related to the issue) are checked into subversion, but they are currently not included in the build package.

Now we have 2 new requirements -

  1. To Include in the build - the specific versions of the properties files or configuration files or database scripts(related to the issue)that are checked into subversion(example version 1 of a.properties file, version 3 of x.sql script etc.)
  2. To create a new build package to include the changed version of a file like a properties file (eveything else should remain the same as the previous build)

What are the best practices for incorporating the above requirements?

Appreciate your help.


You could update your Ant build script to use SvnAnt (http://subclipse.tigris.org/svnant.html), or update it to make the proper command line calls, to add the files to version control prior to the copy. So when you tag your build, the files you added to the working copy would be included in the tag but not the location where the tag was checked out from. That would take care of #1.

For #2, you could also script this in Ant such that a file was updated to include the revision information. Again, SvnAnt would help you here.

Using SvnAnt gives you access to a lot of Subversion command and working copy information and from what I can tell, this is all you'd need to address your needs.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜