Adding Pre- and Post-Build Actions to Visual Studio.NET 2002
We have VS.NET2002 a project that hasn't been updated to VS.NET2003 and logisitically can't for a few weeks. However, we had a need for a post-build file copy. It's a large Online Banking project (since we do eBanking here at Corillian) for a very large Financial Institution, so there's lots of people working on the project at once. Ordinarily the project is built with the increasingly snazzy NAnt so these post-build processes are no biggie. However, sometimes you'd just like to do stuff from VS.NET.
We looked the two obvious ways:
- Custom VS.NET Build Rules Add-In: There's a lovely and simple sample from MSDN in VB.NET with source included. It cleverly (and rightfully) stores it's config info in the .csproj as an extra XML section.
- Use a C++ MakeFile Project and get it to run last with Project Dependancies: This was my first, gut reaction, backed up as at least value by Chris Sell's mention of it. I like it since we wouldn't have to install anything assuming we already had C++ on the box.
So, between a rock and a hard place, we'll use the Custom Add-In for a few months then upgrade and VS2003. It's all good.