How do you manage AssemblyInfo.cs, which is stored in SVN and changes with each assembly

I have the following scenario: An application is created through the IDE and using the build script. The script construct is used for initial setup (dependency sampling, environment setup), for generating binary files, and for the continuous integration process. I want the binaries to have both AssemblyFileVersion month and day during assembly, and svn revision in revision. This causes AssemblyInfo.cs to change at every revision, which creates a lot of noise in the version control log. I can ignore the files, but then, as part of the setup, I will need to restore them.

I would like to know if anyone has any other ideas or what you are doing in this case.

+5
source share
5 answers

Right now, I have decided a solution inspired by Andy White:

  • AssemblyInfo.cs is generated by the AssemblyInfo task from http://msbuildtasks.tigris.org/ and stored outside the source control tree.
  • The version of [major]. [minor]. [month] [day]. [svn revision]. Main and Small are set manually, the rest are controlled by a script line. The Community Tasks package includes both tasks necessary to obtain a working copy of the svn version and date.

Disadvantage:

  • - , script, Visual Studio . , .
+6

, AssemblyInfo.cs , , .

/ , .

, NAnt <asminfo> . , - MSBuild. script AssemblyInfo.cs .

+4

AssemblyInfo trunk RTM/RTW/GA/( ).

Nightly/Beta/RC/QA/( , :) , AssemblyInfo.cs( CI) . Subversion, / .

AssemblyInfo Nightly/Beta , AssemblyInfo trunk , . , , .

FWIW, MSBuild, , , (CruiseControl.NET).

[EDIT] , AssemblyInfo ( ), AssemblyInfo . Major.Minor, Build, Revision QA ( WiX/MSI).

+1

AssemblyInfo.cs , ?

AssemblyFileVersion , , / . , AssemblyInfo.cs.

0

AssemblyInfo. [cs | vb], , Perl script , .

The problem with this system is that VB projects are constantly loading the AssemblyInfo file, which means that the project will have an error on the first load, even before the PreBuild step is completed to create the AssemblyInfo.vb file. We have not yet found a solution to this problem - if someone has an understanding, I would like to hear it ...

0
source

All Articles