views:

55

answers:

4

Hi,

I am using subversion for version control of my code (tortoise SVN on windows and VisualSVN as the server on another computer). Things are going great as far as keeping different versions of my code is concerned, with necessary logs etc. Sometimes I make a few non-essential/trivial changes to the code and commit them before leaving. Sometimes I make essential changes that people who use my code (including me) should know about if they update and run into a few errors because some function has been removed/changed/renamed etc.

Most programs that I download have a version history, and they have important changes as well as minor changes logged nicely. They also have different versions of their program like 1.01, 1.02, 1.5 2.0 etc.

My question is this: Does SVN allow me to change a 'master' revision number of my code. Let's say I made a few hundred commits, and now that I am completely satisfied with my code, I bump it up from version 0.1 to version 0.2. Can SVN track that? If yes, how do I go about doing this? If no, is there another piece of software that can make my life easy as far as version of my software is concerned. Since SVN has 'version' in the name, I am sure this little feature must exist and I am not aware of it.

Currently, I am using a txt file in the 'trunk' folder and I update it with each major change, which is very cumbersome, error-prone (I forget sometimes) and out-dated.

Thanks!

+4  A: 

Yes! You can 'Tag' (SVN tagging) your commit and use this for marking specific versions.

davbryn
+3  A: 

SVN version numbers are not meant to be release numbers (as a release will usually comprise several or many SVN updates). don't try to conflate the two, it's just asking for a headache.

You can SVN version a release version number, just like you'd version any other file: release_number.txt, (or .h, or .inc, or whatever), which contains a release number that you manually change.

tpdi
+2  A: 

Most people use repository tags to achieve that: http://svnbook.red-bean.com/en/1.1/ch04s06.html

janogonzalez
+1  A: 

As others have noted, repository tagging is how you would achieve this. However, you may also find it useful to also use an issue tracking system such as Trac (there are others, but trac is simple and integrates well with Subversion). This will help you track what is in each release and help you plan for which bugfixes you want in the next version. You can create milestones for your future versions and then assign bugs and new features to them. You can also see at a glance which changes made it into each version, eg see the tags view in the trac project

the_mandrill