Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: Application Builder
Hello,
 
i have a nightly build in my TFS server that runs every night and is working completely fine. we plan to create a clickonce application as well which is currently working fine except the publish version (ApplicationVersion) which we want to automatically increment with each build instead of entering it manually. An important point to mention is that we only want the Revision part to be increment by 1 with each build. e.g 1.1.1.1 for first time and 1.1.1.2 for the next build. I have been trying to figure this out for almost 3 days now so pleaseeeee any help in this regard will be highly appreciated.
Please note as alot of information is available for assembly versioning so i am not at all interested in it, i just want my application version to increment so please do point me in this direction.The publish version is a combination of <ApplicationVersion> and <ApplicationRevision> and in my scenerio it is defined as follows
 
<ApplicationRevision>1</ApplicationRevision>
<ApplicationVersion>1.9.4.%2a</ApplicationVersion>
and then
 
    <File.RegEx Path="$(BuildDirectory)/Sources/Client/Client/Client.csproj"
          RegularExpression="&lt;ApplicationRevision&gt;(.*?)&lt;/ApplicationRevision&gt;"
          NewValue="&lt;ApplicationRevision&gt;$(ApplicationRevision)&lt;/ApplicationRevision&gt;" Force="true"/>
        <File.RegEx Path="$(BuildDirectory)/Sources/Client/Client/Client.csproj"
          RegularExpression="&lt;ApplicationVersion&gt;(.*?)&lt;/ApplicationVersion&gt;"
          NewValue="&lt;ApplicationVersion&gt;$(ApplicationVersion)&lt;/ApplicationVersion&gt;" Force="true"/>
But the value is never incremented after first run. after the first run the value is always 1.9.4.1. Is there any way that it should be incremented for the next Build. I have been pulling my hairs all day long but cant figure it out so pleaseee any idea... have tried application revision with *+1, #+1 ...
will be really thankful.
 
Regards
 
[edit]Code blocks corrected. Urgency deleted: It may be urgent to you, but it isn't to us. All that your stressing the urgency does is to make us think you have left it too late, and want us to do it for you. This annoys some people, and can slow a response. - OriginalGriff[/edit]
Posted 1-Apr-11 1:03am
Edited 1-Apr-11 1:07am
(no name)1.2M
v2
Comments
Dylan Morley at 1-Apr-11 6:07am
   
I would look into this, but I'm currently helping someone else out.
 
Their request is 'Really Really Really Really Really urgentttz', so it outranks yours by 3 'Reallys', sorry.
chouhdary at 1-Apr-11 6:24am
   
Thanks Dylan.. i will be waiting Really really really :)
chouhdary at 3-May-11 8:08am
   
Dylan it has been a month of waiting now :)

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 320
1 DamithSL 265
2 CPallini 235
3 Maciej Los 190
4 Sergey Alexandrovich Kryukov 184
0 OriginalGriff 5,415
1 DamithSL 4,422
2 Maciej Los 3,820
3 Kornfeld Eliyahu Peter 3,470
4 Sergey Alexandrovich Kryukov 2,911


Advertise | Privacy | Mobile
Web04 | 2.8.141216.1 | Last Updated 1 Apr 2011
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100