Answered by:
MSBuild for a Web Application, Published Website missing newly compiled project DLL?

Question
-
User-159225446 posted
I'm using the VS command line tool and trying to build and deploy a web application (which is a feat I've heard am finding out). I've tried using the solution SLN file, and tried using just the project file CSProj.
What the output shows (output folder), the root has the reference dlls and the newly built project DLL. Then there is a _PublishedWebsite folder with a working website. But what I've noticed is that the project dll in '_PublishedWebsite' is the older one from source control (not just built). And if I delete the project DLL prior to running MSBuild script I get a nasty 'could not find file' error?
Most Configuration Mgmt (CM) dept's check out the source and do not bring down the project compiled DLL (which is what ideally I want to do). My CM is correctly set-up with a build machine NOT having Visual Studio on it, using standard practice.
But either way the '_PublishedWebsite' doesn't contain the newly compiled project dll that is in the root of the output folder. My script(and I've tried many): C:\Program Files (x86)\Microsoft Visual Studio 11.0>msbuild c:{location}{projectfile}.csproj /m /T:Build;publish /p:Configuration=Release;DeployOnBuild=true;PublishProfile=Release;OutDir=C:{directory}
Thursday, November 7, 2013 8:16 AM
Answers
-
User-166373564 posted
Hi chris
Published Website missing newly compiled project DLLI think this issue is related with your publish procedure, please take a look at MSBuild Command Line Reference(http://msdn.microsoft.com/en-us/library/vstudio/ms164311(v=vs.100).aspx) first, and then learn how to publish your web site using MSbuild, you can refer the discussion to do that, http://stackoverflow.com/questions/3097489/how-to-publish-web-with-msbuild .
Regards
- Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
Monday, November 18, 2013 4:04 AM
All replies
-
User1992938117 posted
Can you try using local copy true for the referenced dll in your application.
Thursday, November 7, 2013 1:54 PM -
User-159225446 posted
It's not a referenced DLL. It is the project DLL.
Thursday, November 7, 2013 3:29 PM -
User-166373564 posted
Hi chris
Published Website missing newly compiled project DLLI think this issue is related with your publish procedure, please take a look at MSBuild Command Line Reference(http://msdn.microsoft.com/en-us/library/vstudio/ms164311(v=vs.100).aspx) first, and then learn how to publish your web site using MSbuild, you can refer the discussion to do that, http://stackoverflow.com/questions/3097489/how-to-publish-web-with-msbuild .
Regards
- Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
Monday, November 18, 2013 4:04 AM