Reputation: 194
I am setting up a gerrit server. I want some projects to have the verified label, where a jenkins build, if successful will set the verified flag. This works fine for me.
I also have some projects which doesn't need a jenkins build to verify. So for this I want to disable the Verified flag and the changes be submit-able on +2 code review.
From gerrit documentation, adding an empty label in parent will remove the label for child. How exactly to do this? I created a intermediate project. But on trying to add an empty label
[label "Verified"]
I am getting the below error.
remote: Processing changes: refs: 1, done
remote: error: Invalid project configuration:
remote: error: project.config: Invalid defaultValue "0" for label "Verified"
To ssh://<gerrit server>:29418/NoVerify
! [remote rejected] meta/config -> refs/meta/config (invalid project configuration)
error: failed to push some refs to 'ssh://<gerrit server>:29418/NoVerify'
How can I solve this? Or if I am adding the empty label wrong, how to add it properly.
Upvotes: 2
Views: 3197
Reputation: 6842
I had the same problem. The other solutions didn't work.
However, setting the function to NoOp in the project.config
made the label go away.
[label "Verified"]
function = NoOp
Upvotes: 2
Reputation: 400
Just add the following string after [label "Verified"]
section:
value = 0 No score
Upvotes: 0
Reputation: 21
Try to add the following in .projectconfig on meta/config branch. This will skip "verified +1" and enable the submit.
[label "Verified"]
defaultValue = 1
Upvotes: 2