Search code examples
c#visual-studio-2015app-configslowcheetah

Why is VS2015 generating old/incorrect app.exe.config file?


I'm working on a windows service and using SlowCheetah to manage the transforms. I added some settings and therefore updated the app.config file for the first time in months, and for some reason when I build the Debug configuration it generates an old version of app.config with a modify date from six weeks ago (Jan 3rd.)

To make matters worse, looking through the source control history it doesn't look like the file was ever checked in with the changes that are showing up when I build. That is, one setting is set to a different url for me to test something... but that was never checked in.

If I build in Release or Test configurations it works perfectly.

I've tried:

  • cleaning/rebuilding the solution
  • Deleting/recreating the the app.config file (It generated the 1/3 version even - when I build with file deleted!)
  • Restarting Visual Studio
  • Rebooting my computer

Nothing works and none of the changes I make in the config file are reflected when I build Debug.

Any ideas why or how to fix it?


Solution

  • Did you try looking at the post build section? Sounds like something there is overriding the built version with a previous one.