{"id":15136868,"url":"https://github.com/silvio/gerrit-rust","last_synced_at":"2025-09-29T06:30:54.293Z","repository":{"id":62439405,"uuid":"64561712","full_name":"silvio/gerrit-rust","owner":"silvio","description":"gerrit cli client","archived":true,"fork":false,"pushed_at":"2019-03-01T17:51:36.000Z","size":265,"stargazers_count":5,"open_issues_count":7,"forks_count":3,"subscribers_count":4,"default_branch":"master","last_synced_at":"2024-11-14T16:44:46.272Z","etag":null,"topics":["api","api-client","cli","curl","gerrit","rust"],"latest_commit_sha":null,"homepage":null,"language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mpl-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/silvio.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE-MPL-2.0","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2016-07-30T19:55:45.000Z","updated_at":"2023-01-28T11:49:11.000Z","dependencies_parsed_at":"2022-11-01T22:00:41.260Z","dependency_job_id":null,"html_url":"https://github.com/silvio/gerrit-rust","commit_stats":null,"previous_names":[],"tags_count":24,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/silvio%2Fgerrit-rust","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/silvio%2Fgerrit-rust/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/silvio%2Fgerrit-rust/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/silvio%2Fgerrit-rust/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/silvio","download_url":"https://codeload.github.com/silvio/gerrit-rust/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":234597573,"owners_count":18857980,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["api","api-client","cli","curl","gerrit","rust"],"created_at":"2024-09-26T06:41:38.982Z","updated_at":"2025-09-29T06:30:53.969Z","avatar_url":"https://github.com/silvio.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![Build Status](https://travis-ci.org/silvio/gerrit-rust.svg?branch=master)](https://travis-ci.org/silvio/gerrit-rust)\n\n# Introduction\n\n`gerrit-rust` is a console client for gerrit written in rust. This is a **rust\nlearner** project. Have patience with me :-)\n\nCurrently tested with Gerrit V02.09 and V02.13.\n\n## Contribution\n\nCommon github workflow: fork, clone, branch, commit, push and then pullrequest.\nI'm happy about every PR, but I will ask questions about changes to learn from\nyour knowledge.\n\n# Dependency\n\n*   A installed `git` binary in `$PATH`\n*   gerrit server with installed download-plugin\n\n# Manual \u0026 Ideas\n\nSome design considerations here. Implemented features marked with `[x]`. All\nother ideas are todos and marked with `[ ]`.\n\n*   [ ] semver at version 1.0.0. Before this version no semver!\n*   remove external depency to host\n    *   [ ] git binary\n    *   [ ] gerrit with download plugin\n\n\n*   manage of topics over more than one repository (git submodules like)\n\n    *   [x] **0.1.0** `ggr topic forget \u003cBRANCHNAME\u003e [-R]`  \n        Delete a branch at mainfolder and and with `-R` in all subfolders.\n\n        *   [ ] Add option `-s` in conjunction with `-R` to remove all branches\n            recursive which have no commit and the repositories are clean. Warn\n            unclean repositories/branches.\n\n    *   [x] **0.1.8** `ggr topic checkout \u003cBRANCHNAME\u003e`  \n        Checkout a branch on all repositories.\n        *   [x] **0.1.8** first check base folder if checkout happened sync all\n            submodules than checkout changes for topic on subfolders\n\n    *   [x] **0.1.7** \u003cs\u003e`ggr topic pull ...`\u003c/s\u003e  \n        same as `ggr topic fetch`. This sub function is renamed because `fetch`\n        is more in line with git speak than `pull`.\n\n    *   [x] **0.1.8** `ggr topic fetch [-f] [-b branchname] \u003ctopicname\u003e`  \n        fetch latest version of commits for a topic. Create for all\n        changes a branch with the patch identifier as name, or with `-b` with\n        a given branchname.\n        * [x] **0.1.9** Add tracking information via `--track \u003cbranch\u003e` option.\n        * [x] **0.1.14** Add `--closed` option to pull closed (merged) topics\n        * [x] **0.1.21** Add `-a` get history of topic. See `topic history`.\n\n    *   [x] **0.1.21** `ggr topic history \u003ctopicname\u003e`  \n        fetch all versions of all changes within \u003ctopicname\u003e as tags. The tag\n        format is `ggr/\u003ctopicname\u003e/\u003ctopicid\u003e`. The `topicid` is the reference\n        number plus version of the patch.\n\n    *   [x] **0.1.17** `ggr topic reviewer [\u003cTOPIC\u003e] [-r \u003c+/-MAIL\u003e,...]`  \n        Add(+) or remove(-) reviewer (`-r`) from topic. Without an option we\n        receive a list of all reviewers on this topic.\n        * [x] **0.1.17** `-v`/`--verbose` for detailed view of approvals\n        * [ ] Without TOPIC it used the actual topic (!=master) on base and\n              submodules.\n        * [ ] Add `--format` option for formating of output. Using of rust\n              variable and formating informations like `{email}`,\n              `{email:15.2}`.\n\n    *   [x] **0.1.18** `ggr topic abandon|restore [\u003cTOPIC\u003e]`  \n        Abandon/restore a complete topic.\n        *   [ ] Without TOPIC it uses the actual topic\n        *   [x] **0.1.18** `[-m \u003cMESSAGE\u003e]` adds a abandon message to all\n            changes in this topic\n        *   [ ] `[-n \u003cNONE|OWNER|REVIEWERS|ALL\u003e]` notifiy a group of accounts\n            about this abandon action or don't notify (via `NONE`). Default is\n            `ALL`.\n\n    *   [x] **0.1.19** `ggr topic verify [\u003cTOPICNAME\u003e] [-c \u003ccode-review\u003e] [-l \"\u003crevie-label\u003e\"] [-m \u003cMESSAGE\u003e]`  \n        Gerrits labels are configurable on server side. Via `-l` option the\n        label can be accessed. (e.g. `-l \"Code-Review:2\"`). Option `-c \u003cVALUE\u003e`\n        is a convenient option for `-l \"Code-Review:\u003cVALUE\u003e\"`. Currently only\n        `-2/-1/0/1/2` as values for labels possible.\n        Additionaly a message can appended on all commits of a topic.\n        *   [x] **0.1.21** Without option a overview of review process is\n            printed\n\n* Query changes\n\n    *   [x] **0.1.0** `ggr changes query \u003cQUERY\u003e`\n        query a searchstring to gerrit server. Use as `QUERY` the same syntax\n        as in gerrit web frontend. eg\n\n        *   [x] **0.1.7** Add `--regexp-selector` to show only keys selected by\n            regular expression.\n            This remove the --fields selector introduced in 0.1.4.\n\n        *   [x] **0.1.6** Add a `--human` option to print it in human readable\n            format.\n\n        *   [x] **0.1.4** Add `--field-list` to get all selectable fields,\n            usable for `--fields` option on a second call.\n\n        *   [x] **0.1.4** Add `--raw` for json in raw format. Usable for pretty\n            printer over pipe\n\n        *   [x] **0.1.4** Option `-o`/`--ofields` to get additional information\n            of changes back (like REVISION etc ...)\n\n        Examples:\n\n        *   `ggr changes query status:open is:watched n:2`: query open changes\n        which `watched` flag.\n\n\n*   [x] **0.1.5** Use of curl-rs as http client\n*   [x] **0.1.0** Use a config file `.ggr.config` in TOML format\n\n    *   `api`: base url with schema (http)\n    *   [x] **0.1.3** User authentication (**deprecated since 0.1.9**)\n        *   `username`: username for login\n        *   `password`: password for login\n        [x] **0.1.9** only `.netrc` settings are respected for username and\n            password. u/p in config file are ignored\n    *   `root`: true if this is the uppermost project of all repositories\n        underneath\n    *   [x] Authentication (e.g.: digest, basic)\n        *   [x] `digest` and `basic` are supported. Current implementation\n            calls both. First one is `basic` and second one is `digest`.\n\n    *   Consider to configure via config file or put all settings into\n        as entries in `.git/config`.  \n        The values are same for config file and git-config approach. For the\n        git-config we use `ggr-` as a prefix.\n\n    *   provide a configuration frontend\n\n        *   [ ] `ggr config set baseurl 'http://localhost'`: set new `baseurl`\n        *   [ ] `ggr config unset -C project1 root`: remove `root` in project1\n            repository\n        *   [ ] `ggr config set root`: set root for current repository\n        *   [x] **0.1.0** `ggr config list`: list all options\n            *   [ ] ... with origin of setting\n        *   [ ] `ggr config generate --base \u003c...\u003e ...`: generates\n            a `.ggr.config` file\n\n    *   [x] **0.1.9** Use `$HOME/.netrc` file to get username and password.\n\n\n*   [ ] add a `--dry-run` option to print what we want to do, but we don't do\n        it\n    *   [ ] changes fetch\n    *   [ ] gerritapi changes abandonchange\n    *   [ ] gerritapi changes create\n    *   [ ] topic fetch\n    *   [ ] topic abandon\n    *   [ ] topic checkout\n    *   [ ] topic create\n    *   [ ] topic fetch\n    *   [ ] topic forget\n    *   [x] **0.1.21** topic history\n    *   [ ] topic restore\n    *   [ ] topic reviewer\n    *   [ ] topic verify\n\n* Library features\n\n    *   [x] **0.1.16** cli needs a subcommand to do lowlevel task -\u003e gerritapi\n\n    *   [x] **0.1.0** implement base for http requests and responses\n\n    *   [ ] build a feature complete library to work with gerrit servers\n\n        *   [ ] access endpoint\n        *   [ ] accounts endpoint\n        *   [ ] changes endpoint\n            *   [x] **0.2.0** Create change\n            *   [x] **0.2.0** Query Changes\n            *   [X] **0.2.4** Get Change\n            *   [x] **0.2.4** Get Change Detail\n            *   [ ] Get Topic\n            *   [ ] Set Topic\n            *   [ ] Delete Topic\n            *   [ ] Abandon Change\n            *   [x] **0.2.2** Restore Change\n            *   [x] **0.2.2** Rebase Change\n            *   [ ] Move Change\n            *   [ ] Revert Change\n            *   [ ] Submit Change\n            *   [ ] Changes Submitted Together\n            *   [ ] Publish Draft Change\n            *   [ ] Delete Draft Change\n            *   [ ] Get Included In\n            *   [ ] Index Change\n            *   [ ] List Change Comments\n            *   [ ] List Change Drafts\n            *   [ ] Check Change\n            *   [ ] Fix Change\n        *   [ ] reviewer endpoint\n            *   [x] **0.2.1** List Reviewers\n            *   [ ] Suggest Reviewers\n            *   [x] **0.2.1** Get Reviewer\n            *   [x] **0.2.1** Add Reviewer\n            *   [x] **0.2.1** Delete Reviewer\n            *   [ ] List Votes\n            *   [ ] Delete Vote\n        *   [ ] Revision Endpoints\n            *   [ ] Get Commit\n            *   [ ] Get Revision Actions\n            *   [ ] Get Review\n            *   [ ] Get Related Changes\n            *   [x] **0.2.3** Set Review\n            *   [ ] Rebase Revision\n            *   [ ] Submit Revision\n            *   [ ] Publish Draft Revision\n            *   [ ] Delete Draft Revision\n            *   [ ] Get Patch\n            *   [ ] Get Mergeable\n            *   [ ] Get Submit Type\n            *   [ ] Test Submit Type\n            *   [ ] Test Submit Rule\n            *   [ ] List Revision Drafts\n            *   [ ] Create Draft\n            *   [ ] Get Draft\n            *   [ ] Update Draft\n            *   [ ] Delete Draft\n            *   [ ] List Revision Comments\n            *   [ ] Get Comment\n            *   [ ] List Files\n            *   [ ] Get Content\n            *   [ ] Download Content\n            *   [ ] Get Diff\n            *   [ ] Get Blame\n            *   [ ] Set Reviewed\n            *   [ ] Delete Reviewed\n            *   [ ] Cherry Pick Revision\n        *   [ ] config endpoint\n            *   [x] **0.2.0** Get Version\n            *   [ ] Get Server Info\n            *   [ ] Confirm Email\n            *   [ ] List Caches\n            *   [ ] Cache Operations\n            *   [ ] Get Cache\n            *   [ ] Flush Cache\n            *   [ ] Get Summary\n            *   [ ] List Capabilities\n            *   [ ] List Tasks\n            *   [ ] Get Task\n            *   [ ] Delete Task\n            *   [ ] Get Top Menus\n            *   [ ] Get Default User Preferences\n            *   [ ] Set Default User Preferences\n            *   [ ] Get Default Diff Preferences\n            *   [ ] Set Default Diff Preferences\n        *   [ ] groups endpoint\n        *   [ ] plugins endpoint\n        *   [ ] projects endpoint\n\n\n*   Removed functionality\n\n    *   [x] `ggr topic create \u003cBRANCHNAME\u003e [-r sub:rev]`  \n        Removed since **0.1.22**, use instead `git submodule foreach 'git\n        branch \u003ctopicname\u003e; true'`  \n\n        Old functionality:\n\n        Create branch at main folder and specified subfolders. If a branch with\n        same name exists it isn't touched. `rev` is the reference where branch\n        should created Defaults to `orign/master`. For base folder use `-r .`.\n\n\n*   Other Ideas\n\n    *   [x] **0.1.9** implement a log mechanism to get debugging information\n        via loglevel switch\n\n    *   [x] *0.1.20* `ggr changes fetch CHANGEID`\n        Fetchs a changeid CHANGEID and his ancestors. The branch name is the\n        CHANGEID name.\n\n    *   [x] **0.1.16** do work to support more than one gerrit server\n\n    *   [x] **0.1.14** create a helper script for setup of development\n        environment\n\n        *   [x] docker based gerrit server  \n            found docker image `docker pull openfrontier/gerrit`\n        *   [x] setup password and username for gerrit\n        *   [x] autogenerate git repositrories and submodules\n        *   [x] setup gerrit for this repositories\n        *   [x] auto push master branches to gerrit\n\n    *   [ ] `ggr stat [-F \u003cdate\u003e] [-T \u003cdata\u003e]`  \n        some statistics like opened and closed review since a week or between\n        a timespan. via iso-8601 like `date -Is`.\n\n        Examples:\n\n        *   `ggr stat -F 1w`: last week to now\n        *   `ggr stat -F 2015-12-31 -T 2016-02-01`: from 01.01.2016T00:00 till 01.02.2016T23:59:59\n        *   `ggr stat -F 2016-01-01`: from 02.01.2016T00:00 till now\n        *   `ggr stat -T 2016-02-01`: from begin of gerrit usage till 01.02.2016T23:59:59\n\n    *   [ ] `ggr topic list -s`  \n        List all development branches and the repositories. With `-s` it\n        includes the commits in the branch like `git submodule summary`.\n\n    *   [ ] `ggr topic push [-b] [\u003cBRANCHNAME\u003e]`  \n        Push changes to gerrit. Without `-b` its pushed to gerrit. With option\n        `-b` its pushed to a build server. Without branchname the current\n        branch is pushed.\n\n    *   [ ] `ggr topic rename OLDTOPIC TOPIC`  \n        Rename OLDTOPIC to TOPIC\n        *   [ ] make OLDTOPIC optional, the current topic is renamed\n\n    *   reviewer per commit\n    *   reviewer per repository\n\n    *   status of branches  \n        shows status of a branch (remote and local like `git remote show ...`\n\n        *   `ggr status [\u003cBRANCHNAME\u003e]`\n\n    *   Support for `.repo` folder\n\n    *   Consider to use https://github.com/gsingh93/trace\n    *   Consider to use https://github.com/ticki/termion\n\n    *   [x] **0.1.11** Document `gerritlib::call` module\n\n    *   [x] **0.1.5** Add .travis.yml\n\n# gerrit demo server local on your host via docker\n\nThis creates a dockercontainer which is connectable via http://localhost:8080.\nThe server is setup for development and all accounts can do all things.\nIt generate or use a `DOCKER-FOR-GERRIT` folder containing of settings,\nrepositories and ssh-keys.\n\n```text\ndocker run --rm -it \\\n           -h localhost\n           -p 8080:8080 -p 29418:29418 \\\n           -v /development/projects/DOCKER-FOR-GERRIT:/var/gerrit/review_site \\\n           --name gerrit \\\n           openfrontier/gerrit:latest\n```\n\n\n## useful links\n\n* gerrit api documentation: \u003chttps://gerrit-review.googlesource.com/Documentation/rest-api.html\u003e\n* request, response design from: \u003chttps://github.com/gefolderstsentry/sentry-cli\u003e\n\n# License\n\nLicensed under\n\n*   Mozilla Public License 2.0 ([LICENSE-MPL-2.0](LICENSE-MPL-2.0) or https://www.mozilla.org/media/MPL/2.0/index.txt)\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsilvio%2Fgerrit-rust","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsilvio%2Fgerrit-rust","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsilvio%2Fgerrit-rust/lists"}