Geeks With Blogs
Fahd Siddiqui [Problem Solved]

I came across this problem at work that required me to make some dlls a part of the web project, so that when we would deploy the web project, these dlls would be deployed as well. These dlls could be third party dlls, and the idea was that all that needed to be done was drop these dlls in a folder called "Plugins" and it should work. Well, everything did work on our development machines just fine, except that on the build server, the dlls were not being correctly deployed to the actual website location.

Of course, the problem was that these dlls were being manually put into the "Plugins" folder, but the project file (*.csproj) did not recognize these files as content files. And so, at deployment it would leave these files behind. What I needed was somehow to tell the project that whatever files you find in the "Plugins" folder should be treated as content. The way to do that is to open the *.csproj file and insert the following line at an appropriate position (or where all the other content files are located.

<Content Include="Plugins\*" /> 

 

The above line makes sure any file within the folder gets deployed as content without explicitly setting the file as content in advance. Hope this helps.

 


Posted on Thursday, September 16, 2010 6:37 PM | Back to top


Comments on this post: Wild cards to include files in your project

No comments posted yet.
Your comment:
 (will show your gravatar)


Copyright © fahdsiddiqui | Powered by: GeeksWithBlogs.net