I have two packages \ projects "A" and "B". Where "B" depends on "A" and uses it as a reference. When my build process in TFS creates "A", it creates the nuget package from nuspec and provides it with a new version and puts it in my private TFS packages.
My problem is to create a well-defined package “B” in each assembly “B”. In the file "B.nuspec" I write the version of the current package "A":
<dependencies>
<group targetFramework=".NETFramework4.5">
<dependency id="A" version="[1.0.0.3]" />
</group>
</dependencies>
When I create a new package “A”, I update the project “B” to use the new version “A” → it also updates “package.config” with the latest version “A” as expected. The problem is that the build process “B” creates the package “B” from the nuspec file with the old dependency “A” . And I want him to use version "A" from "packages.config".
Is there an automatic way to do this? (without manually modifying the nuspec file in each new version of "A") I was thinking of creating a small "Post-Build" process that read the version from B-> "packages.config" and write it to the "B.nuspec" file in the section dependencies "A". Does TFS support this in a simpler way?
source
share