Search code examples
visual-studio-2010setup-deployment

Adding Files to a Project Programmatically VS 2010


I have build a deployment .exe that minifies and combines JS and CSS files. Everything works great except that when I publish my website these files are not published. This is because these files are added to the proper directories within my project but are not included in the project.

I know there is a option to include all files when publishing, but I don't want to do that. I simply want to be able to programmatically add these couple of JS and CSS files to the solution during the deployment process.


Solution

  • I ended up just writing the XML to my csproj file.