SQL Server Management Studio and TortoiseSVN

In this post:


Update: SQL Source Control was released a while back! See my article on Simple-Talk for more information.

At work we maintain a few SQL Server Management Studio (SSMS) solutions for our SQL views, stored procedures and functions. We also use TortoiseSVN for source control. Unfortunately, there are no SVN add-ins for SSMS and the ones for Visual Studio don’t work (VisualSVN, AnkhSVN). Its a bit frustrating that SSMS is built on the same technology as Visual Studio, but lacks so many of the features that I’ve grown accustomed to, such as the Add-in Manager.

Red Gate, however, is currently working on a add-in called SQL Source Control with a planned release in 2010. But what to do until then? Well, there is one officially supported point of extensibility in SSMS: External Tools. Here are a few that I’ve been using with TortoiseSVN lately:

Title: SVN Commit  
Command: C:\Program Files\TortoiseSVN\bin\TortoiseProc.exe  
Arguments: /Command:commit /path:"$(SolutionDir)"
Initial directory: $(SolutionDir)

Title: SVN Update  
Command: C:\Program Files\TortoiseSVN\bin\TortoiseProc.exe  
Arguments: /Command:update /path:"$(SolutionDir)"  
Initial directory: $(SolutionDir)

Title: SVN Log (Solution)  
Command: C:\Program Files\TortoiseSVN\bin\TortoiseProc.exe  
Arguments: /Command:log /path:"$(SolutionDir)"
Initial directory: $(SolutionDir)

Title: SVN Log (Current Item)  
Command: C:\Program Files\TortoiseSVN\bin\TortoiseProc.exe  
Arguments: /Command:log /path:"$(ItemFileName)$(ItemExt)"  
Initial directory: $(ItemDir)

Title: SVN Diff  
Command: C:\Program Files\TortoiseSVN\bin\TortoiseProc.exe  
Arguments: /Command:diff /path:"$(ItemFileName)$(ItemExt)"  
Initial directory: $(ItemDir)