0

Im trying to setup a pre-commit hook for email notification using VisualSVN. When I try to add a test file to the repository and commit it, I get an error that includes verbage such as "VisualSVNServerHooks: E205000: Invalid revision number supplied..."

Im using the basic email notification setup referenced from here https://www.visualsvn.com/support/topic/00018/

What Im using (settings changed)

"%VISUALSVN_SERVER%\bin\VisualSVNServerHooks.exe" ^
    commit-notification "%1" -r %2 ^
    --from "noreply@nowhere.com" --to "my_email_address@somewhere.com " ^
    --smtp-server mail.something.com

If I dummy up the command and replate %2 with 123, it works. Could the 2nd argument not be getting supplied to the command?

BitShift
  • 123
  • 2
  • 14

1 Answers1

1

It has to be a post-commit hook, not pre-commit. Pre-commit hook runs before new revision is created in a repository, therefore it does not supply a revision number as %2 input parameter.

bahrep
  • 29,961
  • 12
  • 103
  • 150
  • Duh! It even says post-commit in the documentation link I posted. for some reason my brain read it as pre-commit. I updated the settings and it works as expected now. Thank you! – BitShift Sep 25 '15 at 12:28