Gerrit +2代码审核标签不可见

时间:2015-11-24 13:48:38

标签: gerrit

我是Gerrit的新手。刚刚开始对Gerrit进行代码审查。

对于某些存储库,我能够看到 +2代码审核标签

enter image description here

但是对于某些存储库来说,它是不可见的。

enter image description here

有人可以帮助我找出原因。

我已经检查了我的许可状态。我有管理员角色。

修改:如果有人使用+1代码审核标签审核了代码并且+1已经过验证,则表示未显示submit按钮

有人可以帮助我理解这一点。

1 个答案:

答案 0 :(得分:0)

我得到了解决方案,我们可以通过编辑project.config文件来实现。

enter image description here

点击编辑配置按钮,然后添加这样的参数。

    [label "Your-Label-Here"]
            function = MaxWithBlock
            value = -1 Your -1 Description
            value =  0 Your No score Description
            value = +1 Your +1 Description

了解更多信息请查看给定文件的快照

[access "refs/*"]
    read = group DA-Admins
    read = group Registered Users
    forgeAuthor = group Registered Users
    label-Verified = -1..+1 group Registered Users
    create = group Pushers
    forgeCommitter = group Pushers
    forgeServerAsCommitter = group Pushers
    push = +force group Pushers
    pushMerge = group Pushers
    pushTag = group Pushers
    pushSignedTag = group Pushers
[access "refs/for/*"]
    push = group Registered Users
    pushMerge = group Registered Users
[access "refs/heads/*"]
    label-Code-Review = -2..+2 group Project Owners
    label-Code-Review = -1..+1 group Registered Users
    label-Code-Review = block -2..+2 group Change Owner
    label-Verified = -1..+1 group Registered Users
    submit = group Project Owners
[access "refs/meta/config"]
    read = group Registered Users
    label-Code-Review = -2..+2 group Administrators
    label-Code-Review = -2..+2 group Project Owners
    submit = group Administrators
    submit = group Project Owners
[access "refs/tags/*"]
    create = group Project Owners
    pushTag = group Project Owners
[access "refs/notes/review"]
    push = group Registered Users
[receive]
    requireChangeId = true
[submit]
    mergeContent = true
[project]
    description = This is a description
[label "Code-Review"]
        function = MaxWithBlock
        abbreviation = R
        copyMinScore = true
        value = -2 Do not submit
        value = -1 I would prefer that you didn't submit this
        value =  0 No score
        value = +1 Looks good to me, but someone else must approve
        value = +2 Looks good to me, approved
        copyAllScoresOnTrivialRebase = true
        copyAllScoresIfNoCodeChange = true
    defaultValue = 0