3

We are using Subversion Edge 5.2 on Windows.

Whenever we create a repo, a hooks folder within the repo is pre-populated with the following templates:

  1. post-commit.tmpl
  2. post-lock.tmpl
  3. post-revprop-change.tmpl
  4. post-unlock.tmpl
  5. pre-commit.tmpl
  6. pre-lock.tmpl
  7. pre-revprop-change.tmpl
  8. pre-unlock.tmpl
  9. start-commit.tmpl

Where are the master copies kept? I want to override post-commit.tmpl so whenever we create a new repo it uses our version, it saves us the manual step of going to the folder and replacing the file manually.

TIA

Pedro Vera
  • 41
  • 3

1 Answers1

3

I think this is a misunderstanding: These hooks are examples and templates (.tmpl). They are not runnable so even if you modify them, you need to make them executable. So a manual step is still necessary.

They are defined directly in SVN Source code: Link to repos.c (search for "/* Start-commit hook. */")

So unfortunately you cannot change the default hook templates(unless you want to patch svn sourcecode and build it yourself..)

Peter Parker
  • 29,093
  • 5
  • 52
  • 80
  • I do understand that they are templates/examples. To clarify, I was hoping to be able to override the creation of post-commit.tmpl and instead use the post-commit.bat that we got working. Since the folder and templates are being generated from code this is obviously not possible unless I am willing to patch SVN. Thanks! – Pedro Vera Aug 15 '17 at 10:42