Linking fails due to SVN pre-commit hooks
Published 16 July 2015
If you have Subversion pre-commit hooks that require a comment, or that require a comment of a particular format, linking a database for the first time might fail.
This happens because the first time a database is linked, SQL Source Control adds a folder structure and some accompanying metadata to source control, and the default comment may not be appropriate.
If your pre-commit hooks stop you linking a database within SQL Source Control, you can create the initial link manually. To do this:
- Using your source control client (eg TortoiseSVN), create a new, empty folder in your repository.
This will be the folder that contains the database. The URL for the folder location is used to link the database in SQL Source Control.
- Download this .zip file containing the folder structure and metadata.
- Unzip the .zip file and commit the contents to source control in the folder you created.
When you commit, add an appropriate comment.
- Link the database to SVN.