I currently have a project that utilizes Entity Framework Code-First migrations and Web Publish, where the connectionStrings are stored in the web.config file.
It has come time to move the connectionStrings outside of the web.config, and as such we put them into a connectionString.config file, and have slowcheetah transforming them on webpublish.
connectionStrings.config
<connectionStrings>
<!-- Testing Databases -->
<add
connectionString="server=testserver;database=testdatabasename;user id=someid;password=*******"
name="dbname"
providerName="System.Data.SqlClient"
/>
</connectionStrings>
web.config relevant section
<connectionStrings configSource="config\connectionStrings.config">
</connectionStrings>
Now when I load up the dialog box for Web Publish (Build -> Publish Project), In the settings tab I receive the error
No Databases found in the project
This indicates to me that the dialog box isn't intelligent enough to see the configSource and load the data from there. I can confirm that the connectionStrings are loaded properly in my developer environment, and I can also confirm that slowcheetah is properly transforming the config into it's production environment.
Is there a way to have Visual Studio Publish see my configuration config, and allow code-first migrations?