all groups > visual studio .net general > november 2004 >
You're in the

visual studio .net general

group:

VS.NET version problem


VS.NET version problem Pradeep
11/30/2004 9:51:03 AM
visual studio .net general:
Hi,
Herez the scenario I have. Suppose I have projects A, B and C. Project B
uses the out put from Project A and Project C uses the output from project B.
So I can't keep them in a solution. I am using NAnt for building. Everything
seems to be going good except the version problem. Two different developers
working on thier machines when they do builds and check in thier codes, since
each of them is likely to have run different number of builds before
checking in their stuff, we are having issues where different projects have
different version numbers and even though the changes made by one developer
might be the latest one, but if the other developer has run more builds on
his machine, so the changes from the former wont' be taken.
someone here adviced me to add a file AssemblyVersionInfo.cs at the main
level and all the other AssemblyInfo.cs files would take its version from
this file. Can anyone give me more, preferably as much as you can, on this?

Thanks in advance.
Re: VS.NET version problem Carlos J. Quintero [MVP]
12/1/2004 11:19:45 AM
Hi,

[quoted text, click to view]

How is that? Solutions are precisely for projects with dependences! You can
use project references: select the References node of Project B,
right -click Add Reference..., select the Project tab, select Project A and
click Select. Repeat with Project C against project B.

Now, to check that all is fine, right-click Project Dependencies on a
project in Solution Explorer and review both tabs.

[quoted text, click to view]

If you want all projects with the same version, the best approach is to
remove * from the AssemblyVersion attribute and change it in a controlled
fashion, by hand or with some macro, when you are building a new build. To
avoid to change 3 assemblyinfo files each time, you can put a single copy in
the solution folder and add a file link to that copy in each project. This
is done selecting a project in solution explorer, right click Add Existing
File... select the file in the list, click the down arrow in the Open button
of the dialog and select Link File.


--

Carlos J. Quintero

The MZ-Tools all-in-one add-in, now for .NET: http://www.mztools.com



AddThis Social Bookmark Button