Metadata-Version: 2.0
Name: gerrit-hooks
Version: 1.0.0b2
Summary: Utility for writing Gerrit Hooks in python
Home-page: UNKNOWN
Author: Nils Diefenbach
Author-email: nlsdfnbch.foss@kolabnow.com
License: UNKNOWN
Platform: UNKNOWN
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Developers
Classifier: Programming Language :: Python :: 3.5
Classifier: Programming Language :: Python :: 3.6
Classifier: Programming Language :: Python :: 3.7
Classifier: Topic :: Software Development
Classifier: Topic :: Software Development :: Code Generators
Classifier: Topic :: Software Development :: Build Tools
Classifier: Topic :: Software Development :: Version Control
Classifier: License :: OSI Approved :: MIT License

# 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:

```python
> gerrit/hooks/comment-added

#!/usr/bin/env/python3
import gerrit_hooks

options = gerrit_hooks.parse_options(gerrit_hooks.COMMENT_ADDED)

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

```


# Resources

[Gerrit-Hooks Plugin](https://gerrit-review.googlesource.com/admin/repos/plugins%2Fhooks)


