Hello,

I have a project that I can build with a script. I'd like to add version number + release number to my builds. I'm looking for a way to do it automatically. As a result I'd like to get something like that: \deployment\v1.2.3\some.exe When I run exe I'd like it to know that its version is 1.2.3.

1.2 is the actual version that I can setup manually, but .3 I'd like to change every time I run the deployment script, and it should reset when the version changes. I can write a perl script that reads a file and applies proper changes. But maybe there is a standard way to do these things and I'm not aware of it.

Thanks.

Recommended Answers

All 4 Replies

Hey There,

If you use cvs, it will update the minor revision by default every time you check the code out and check it back in.

Ex:

mkdir -p /var/tmp/build
cd /var/tmp/build
cvs co PROJECT_NAME
cvs update -q <--- if you have this directory already and just want to update
cvs ci/update/add

Of course, you'd have to login, etc, first.

If you're using this already it's a good "incidental" feature and you could still force your version tags if you wanted to.

Here's a fairly decent link to tagging with cvs (The main cvs page can be found on Sourceforge.net)

http://www.linux.ie/articles/tutorials/continuingcvs.php

Hope that helps :)

, Mike

Thanks, eggi.
I'm actually using subversion. And I know that it does have similar option. It looks like I have to use build number, because I can have multiple builds of the code before I commit.

Thanks.

Thanks Mike, it was useful!

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.