Page tree
Skip to end of metadata
Go to start of metadata

In order to enable synchronization of Subversion and Git repositories, SubGit installs hooks into Git repository. These hooks are:

  • Git pre-receive hook
  • Git post-receive hook

Presence of these hooks is crucial for SubGit to function properly, and users should never modify or remove these hook scripts. If necessary, above hooks functionality should be placed into user-* scripts that would be called by SubGit at appropriate moments. SubGit install command takes care of already existing hooks and automatically places their contents into the corresponding user-* script files (see Figure 5.2, “Repository after install command is completed”).

Table below shows correspondence between standard hook scripts file names and file names that should be used to put hook functionality into after SubGit is installed. Hooks parameters and return code processing rules are not affected by SubGit. Hooks that are not listed in the table are not used by SubGit and their standard file names are not changed.

standard hook name             hook name after SubGit is installed

pre-receive                    user-pre-receive
post-receive                   user-post-receive

On Windows OS .cmd or .bat extension should be added to Subversion hook file names.

  • No labels