Gerrit Action
Project description
gerritaction
Introduction
gerritaction is a tool used for Gerrit action via Gerrit API.
Prerequisites
- Python >= 3.7.0
Run
git clone https://github.com/craftslab/gerritaction.git
cd gerritaction
pip install -Ur requirements.txt
python action.py --config-file="config.yml" --change-query="since:2024-01-01 until:2024-01-02"
Docker
git clone https://github.com/craftslab/gerritaction.git
cd gerritaction
docker build --no-cache -f Dockerfile -t craftslab/gerritaction:latest .
docker run -it -v /tmp:/tmp craftslab/gerritaction:latest ./gerritaction --config-file="config.yml" --change-query="since:2024-01-01 until:2024-01-02"
Usage
usage: action.py [-h] --config-file CONFIG_FILE
[--account-query ACCOUNT_QUERY] [--change-query CHANGE_QUERY]
[--change-action CHANGE_ACTION] [--group-query GROUP_QUERY]
[--project-query PROJECT_QUERY] [--output-file OUTPUT_FILE]
[-v]
Gerrit Action
options:
-h, --help show this help message and exit
--config-file CONFIG_FILE
config file (.yml)
--account-query ACCOUNT_QUERY
account query (name:john email:example.com)
--change-query CHANGE_QUERY
change query (status:open since:2024-01-01
until:2024-01-02)
--change-action CHANGE_ACTION
change action (add-reviewer:account-id,... delete-
reviewer:account-id,... add-attention:account-id,...
remove-attention:account-id,... approve-change:Code-
Review=+2,... delete-change submit-change)
--group-query GROUP_QUERY
group query (name:admin member:john)
--project-query PROJECT_QUERY
project query (name:test state:active)
--output-file OUTPUT_FILE
output file (.json)
-v, --version show program's version number and exit
Settings
gerritaction parameters can be set in the directory config.
An example of configuration in config.yml:
apiVersion: v1
kind: worker
metadata:
name: gerritaction
spec:
gerrit:
host: http://127.0.0.1/
port: 8080
user: user
pass: pass
License
Project License can be found here.
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 Distribution
gerritaction-1.4.1.tar.gz
(13.4 kB
view details)
Built Distribution
File details
Details for the file gerritaction-1.4.1.tar.gz
.
File metadata
- Download URL: gerritaction-1.4.1.tar.gz
- Upload date:
- Size: 13.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.0 CPython/3.10.13
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 999a8e9cb3b4d80b3e9e258e84e1b207801021788080813af9cef7e2fd197112 |
|
MD5 | 9dc58155feb65693992fee9bbc3f0a7c |
|
BLAKE2b-256 | ab06c74380a824e309bee22a60a3a83ecdffe85734401af88a6e65b6eb1224cd |
File details
Details for the file gerritaction-1.4.1-py2.py3-none-any.whl
.
File metadata
- Download URL: gerritaction-1.4.1-py2.py3-none-any.whl
- Upload date:
- Size: 14.7 kB
- Tags: Python 2, Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.0 CPython/3.10.13
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | bb87062e217e67694978f86168f1018a34cfc40827797924a33121d20d90412d |
|
MD5 | 81b0f820fac709086fab7608dda68d53 |
|
BLAKE2b-256 | d2005ae9c18ef48a21879b601e865c8d068bd9e9189c25e1f1afedc3d3f43a73 |