❔ Package the binaries of another project
We have two projects in a solution, A and B. We'd like B to ship the binaries of A when packaged (not referencing it as a standard library dependency).
There are existing libs we have seen that ship binaries (https://github.com/valentiniliescu/GraphVizNet/blob/master/GraphVizNet/GraphVizNet.csproj#L25) so, that's not exactly the problem. Where we are stuck is forcing A to build when packaging B, and then retrieving the output path for the binaries of A.
6 Replies
it's easier to do with Nuke
with MSBuild it's gonna be tough
a lot of hacks and headaches
with Nuke it should be as straightforward as writing a couple of lines of code
We won't introduce Nuke, very unlikely
with MSBuild you're gonna waste a lot of time even if you do manage to pull it off
you can't retrieve the output path as far as I know
you'll have to hardcode it
as for the reference
you can add the project A as a build time reference
under the condition that some property is set that corresponds to packaging
Yeah, or exclude all assets or whatever
which may or may not exist, I'm not sure
a close enough check would be to check for debug
Was this issue resolved? If so, run
/close
- otherwise I will mark this as stale and this post will be archived until there is new activity.