0

We using gerrit code review tool for code review and verification. Gerrit internally allow to submit code on two criteria 1.Code-Review(-2,-1,0,+1,+2) and 2.Verified(-1,0,+1). I have to add other one my custom criteria to allow submit the code.So how can i achieve this thing.

  • Based on the post you've made, I would recommend spending some time reading documentation in the [Help Center](https://stackoverflow.com/help) so that you have the best chance at getting your question answered. – Brien Foss Feb 17 '18 at 03:18

1 Answers1

0

The Gerrit labels (Code-Review and Verified) are defined in the project.config file of the All-Projects project. Administrators and project owners can define their own labels or customize existing labels by changing the project.config file from the All-Projects project or any other project.

See all information about customized labels on Gerrit documentation.

To change a project.config file do the following:

1) Clone the project (ex: All-Projects)

git clone https://USER@GERRIT-SERVER/a/All-Projects

2) Fetch and checkout the refs/meta/config branch

git fetch refs/meta/config
git checkout FETCH_HEAD

3) Edit the project.config file

EDITOR project.config

4) Add, commit and push to Gerrit

git add project.config
git commit
git push origin HEAD:refs/meta/config

You can also edit the project.config file using the GUI:

Projects > List > SELECT-THE-PROJECT > General > Edit Config