Last post Dec 11, 2012 09:18 AM by Gambino
Mar 28, 2012 06:27 PM|mfearby|LINK
I have a system designed using Visual Studio that has items in the source directory that are technically not part of the solution (I have to click the "Show All Files" button in Solution Explorer to see them) that I want copied to the PackageTmp directory
along with the few .aspx files and the assembly itself. How can I achieve this, without having to become an expert at MS Build / Web Deploy (whose docs are... quite extensive!)?
The reason the files I speak of are not part of the solution is because they are managed outside of Visual Studio and I don't want the hassle of the Team Foundation Server integration getting angry at me for not editing the files the official way (the files
are created/managed with Sencha Designer).
At the moment I'm using Microsoft Sync Toy to copy files to the web server but now that I am using web.config transformations to change connection strings and appSettings for the web service part of the solution (since the system is now in production), I
need to copy some solution files to the PackageTmp directory files before/after building a deployment package.
I've tried the following (as a test) in the Post-build events:
copy "$(ProjectDir)default.js" "$(ProjectDir)obj\$(Configuration)\Package\PackageTmp\"
But when I click the "Build deployment package" button, the post-build event is not being executed, even if I have "Run the post-build event" setting set to "Always". I guess I could click one button then the other, but it would be nice if I could make it
a one-step process.
Mar 28, 2012 06:38 PM|tdykstra|LINK
You can select "All Files in the Project Folder" in the Package/Publish Web tab of Project Properties -- see this item in the deployment FAQ on MSDN:
Mar 28, 2012 06:41 PM|mfearby|LINK
Thanks for the suggestion, but that would copy the full source code for everything; I only want to copy specific files/directories, and that's why I was hoping the Post-build event would actually fire when building a deployment package.
Dec 11, 2012 09:18 AM|Gambino|LINK
Did you get it to work?
I have the same issue.