Require comment / message on all SVN commits for Visual SVN Server
(I've been posting a lot the last few days!) Something that drives me nuts is not having a comment or message when looking at SVN history. It's impossible to know what went on. Even a bad comment is better than no comment. SVN hooks are a great way to solve this. If we make a pre-commit.bat file that checks the commit data for a comment, returns an error code of 1 if it wasn't found (with some text) or returns 0 if the comment is there. Check out the pre-commit hook that I found online (thanks, Anuj Gakhar!) or check out the hook below. @echo off setlocal rem Subversion sends through the path to the repository and transaction id set REPOS=%1 set TXN=%2 rem check for an empty log message svnlook log %REPOS% -t %TXN% | findstr . > nul if %errorlevel% gtr 0 (goto err) else exit 0 :err echo. 1>&2 echo A log message or comment is required to commit 1>&2 exit 1 This works perfectly except for 1 downfall -- you have to distribute it in every freaking reposito...