Binoj Rajan

I am having a solution which holds 48 projects that includes webservices, websites, etc. Now whenever I release a new version I need to update the assembly version of each projects. Is there any option to update the version for the whole projects by updating in a single place instead of changing it in the AssemblyInfo of each project.

Thanks,

- BINOJ




Re: Visual Studio MSBuild How to update the Assembly version for the entire solution

Yewtaah

I've never found a way to do exactly what you are asking, so if there is one, I am curious to hear how it is done.

What I have been able to get work is to have a pre-build step that updates the AssemblyInfo in an automated manner. Using PowerShell or some other scripting technology makes this a pretty painless exercise. My recommendation would be to only have this step run for your release builds.

Hope this helps,
Scott Bateman
Sr. Product Architect
Quorum Business Solutions, Inc.




Re: Visual Studio MSBuild How to update the Assembly version for the entire solution

Steve St.Jean

Binoj,

Have you tried the AssemblyInfoTask It allows you to update the verision numbers within your MSBuild script.

Here's the URL: http://www.gotdotnet.com/codegallery/codegallery.aspx id=93d23e13-c653-4815-9e79-16107919f93e

- Steve






Re: Visual Studio MSBuild How to update the Assembly version for the entire solution

Binoj Rajan

Steve,

I couldn't try it out but it looks exactly what I needed.

Thanks,

- BINOJ






Re: Visual Studio MSBuild How to update the Assembly version for the entire solution

Simon Dahlbacka

Or then you just put all the common stuff, (Company, Copyright et al comes to mind) and AssemblyVersion if you wish into a e.g. ProductInfo.cs, that you include in all projects, either as a link, or then share it to all projects via source control. In that way, you have all the common stuff in just one place and get it automatically synched.