views:

30

answers:

2

I'm looking for a utility that copies all files from a VS2010 solution folder, which are necessary to build the solution, but ignores all other files (.obj files etc). My intended use is for emailing solutions or making them available on a blog etc.

I'd prefer a utility that's portable (runs without having to be installed), but if there is none, I'll settle for whatever's available.

A: 

In the past I've created a new configuration within VS.NET (e.g. Deploy) which builds the code in release mode. I also set the output path for the main application project to build into a separate folder in the root of the project.

If it's a web application, this is a little more problematic as it won't copy the support files. To get over this I use a nant script to copy all of the appropriate files, that are needed but aren't included in the build, into the aforementioned build folder.

James O'Sullivan
A: 

You may want to consider something as simple as a script (via .bat or powershell) that simply runs the solution's build with a /clean and then zips up the entire folder structure into an archive.

No need to be fancy, especially when project can need any number of impossible-to-know files to build. (What happens when a new language is released like F#? If you'd written your tool 3 years ago, you'd have to modify it for that. What happens if someone needs a .txt file or a .mak file to build?)

Greg D
I was thinking more in the lines of copying everything except the files that aren't needed (i.e. those in the bin and obj folders), and stripping source control info from the solution. I'll take your advice and settle for a dirt simple script for now.(Funny you should mention F# - it's the only reason I'm using Visual Studio :-). )
Batibix