Skip to main content

Utility for writing Gerrit Hooks in python

Project description

# Gerrit Hooks Argument Parsers

This library provides pre-built `argparse.ArgumentParser` instances
for gerrit's hooks (linked in the [Resources](#resources) section below).

It allows developers to get started with gerrit hooks faster, by
getting the parsing of command-line arguments for the various hook types
out of the way.

All hooks are supported.

# Installation

pip install gerrit-hooks

# Usage

Writing hooks using gerrit-hooks' argparsers is easy:

> gerrit/hooks/comment-added

import gerrit_hooks

options = gerrit_hooks.parse_options()

print("Change ID: {}".format(options.change))


# Resources

[Gerrit-Hooks Plugin](

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

gerrit_hooks-1.0.0b3-py3-none-any.whl (5.1 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page