Utility for writing Gerrit Hooks in python
Project description
# Gerrit Hooks Interfaces
This library provides argumentparsers for gerrit's hooks-plugin's hook files.
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
parser = gerrit_hooks.build_parser_for(gerrit_hooks.COMMENT_ADDED)
options = parser.parse()
print("Change ID: {}".format(options.change))
...
```
# Resources
## Gerrit Hooks Plugin Repository:
https://gerrit-review.googlesource.com/admin/repos/plugins%2Fhooks
This library provides argumentparsers for gerrit's hooks-plugin's hook files.
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
parser = gerrit_hooks.build_parser_for(gerrit_hooks.COMMENT_ADDED)
options = parser.parse()
print("Change ID: {}".format(options.change))
...
```
# Resources
## Gerrit Hooks Plugin Repository:
https://gerrit-review.googlesource.com/admin/repos/plugins%2Fhooks
Project details
Release history Release notifications | RSS feed
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
Close
Hashes for gerrit_hooks-1.0.0b1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | f0e36a571151fb81507e960cb0ddb38b984d1b78ee86b43f0f31039d5a916c4e |
|
MD5 | 4fe3751cc0634fe2aae90752e92e0c95 |
|
BLAKE2b-256 | ed898451129d23f44f08e5aee95192f97f598c7138f99fc1aa67d0c2e7f84ea6 |