This is explained in the help document of tortoisesvn, where the svn repository is configured on the server to prevent the submission of empty log information.
There are some default hook script templates in each SVN repository, where the pre-commit.tmpl is verified before submission, with this for our purpose.
Because the svn server is created in windows, we use the doscommand to implement it:
Code
Rem Pre commit script
@ Echo Off
Setlocal
Set "Repos = % ~ 1"
Set "Txn = % ~ 2"
Set "Svnlook = G: \ SCM \ SVN \ bin \ svnlook.exe"
For / F " Tokens = * " % I in ( '% Svnlook % log-T " % Txn % " " % Repos % " ' ) Do Set " Logmsg = % I "
If Not " % Logmsg % " = "" Exit 0
echo no log information is entered! 1 > & 2
echo enter a useful message, which changes have you made to Code . 1 > & 2
echo logs are important information for tracking versions. You must enter them. Thank you for your cooperation. :) 1 > & 2
Exit 500
Save this filePre-commit.batIn the hooks directory of the repository.
Enjoy it!