Add submit hook

The submit hook is invoked synchronously when a change is submitted. If
it returns a non-zero exit status, a MergeValidationException is thrown
and the submit is prevented.

This adds back the ability to block submit by a hook. Previously this
was possible with the ref-update hook until its purpose was changed and
only invoked on ref updates such as branch creation, deletion, or fast-
forward by direct push.

Change-Id: Ie4efb90df645ecac01638b23305dc2ffb547192e
4 files changed
tree: 5571ebfe774129cb02f75ac9ea855395e609926b
  1. .gitignore
  2. BUILD
  3. LICENSE
  4. README.md
  5. src/
README.md

Hooks plugin

Gerrit does not support the standard server-side git hooks in the repositories it manages.

This plugin adds support for custom hooks that can be run instead. Refer to the configuration documentation and list of supported hooks for details.