无法在任何场景中找到gerrit中的提交按钮

时间:2017-08-26 19:06:54

标签: git gerrit

我在过去12小时内遇到过一个问题而无法找到gerrit的解决方案。

我已经安装了测试Gerrit实例“2.14.3”。从最近几个小时开始,我试图找到一个提交按钮并且失败了。在谷歌尝试了很多选项和许多参考,但无法获得提交按钮启用。

注意,我正在通过一个注册用户推送更改并尝试通过管理员用户提交,但“SUBMIT”按钮根本没有显示。

检查senario的几个快速命令

git clone http://13.126.209.78:8080/test1
curl -Lo .git/hooks/commit-msg http://13.126.209.78:8080/tools/hooks/commit-msg
touch file1.txt;git add .;git commit -m"adding first"
git push origin HEAD:refs/for/master

并找到“无提交”按钮。 任何线索,我在做错误?

以下是project.config

的详细信息
[project]
    description = Access inherited by all other projects.
[receive]
    requireContributorAgreement = false
    requireSignedOffBy = false
    requireChangeId = true
    enableSignedPush = false
[submit]
    mergeContent = true
[capability]
    administrateServer = group Administrators
    priority = batch group Non-Interactive Users
    streamEvents = group Non-Interactive Users
[access "refs/*"]
    read = group Administrators
    read = group Anonymous Users
[access "refs/for/*"]
    addPatchSet = group Registered Users
[access "refs/for/refs/*"]
    push = group Registered Users
    pushMerge = group Registered Users
[access "refs/heads/*"]
    create = group Administrators
    create = group Project Owners
    forgeAuthor = group Registered Users
    forgeCommitter = group Administrators
    forgeCommitter = group Project Owners
    push = group Administrators
    push = group Project Owners
    label-Code-Review = -2..+2 group Administrators
    label-Code-Review = -2..+2 group Project Owners
    label-Code-Review = -1..+1 group Registered Users
    submit = group Administrators
    submit = group Project Owners
    editTopicName = +force group Administrators
    editTopicName = +force group Project Owners
[access "refs/meta/config"]
    exclusiveGroupPermissions = read
    read = group Administrators
    read = group Project Owners
    create = group Administrators
    create = group Project Owners
    push = group Administrators
    push = group Project Owners
    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 Administrators
    create = group Project Owners
    createTag = group Administrators
    createTag = group Project Owners
    createSignedTag = group Administrators
    createSignedTag = group Project Owners
[label "Code-Review"]
    function = MaxWithBlock
    defaultValue = 0
    copyMinScore = true
    copyAllScoresOnTrivialRebase = true
    value = -2 This shall not be merged
    value = -1 I would prefer this is not merged as is
    value = 0 No score
    value = +1 Looks good to me, but someone else must approve
    value = +2 Looks good to me, approved
[label "Verified"]
    function = MaxWithBlock
    value = -1 Fails
    value =  0 No score
    value = +1 Verified
    copyAllScoresIfNoCodeChange = true

以下是gerrit.config的详细信息

gerrit]
        basePath = git
        serverId = 99472c41-5ed3-411e-a42f-36fdd890ff96
        canonicalWebUrl = http://ip-172-31-2-138.ap-south-1.compute.internal:8080/
[database]
        type = h2
        database = /opt/review_site/db/ReviewDB
[index]
        type = LUCENE
[auth]
        type = DEVELOPMENT_BECOME_ANY_ACCOUNT
[receive]
        enableSignedPush = false
[sendemail]
        smtpServer = localhost
[container]
        user = root
        javaHome = /usr/lib/jvm/java-1.8.0-openjdk-1.8.0.141-2.b16.el7_4.x86_64/jre
[sshd]
        listenAddress = *:29418
[httpd]
        listenUrl = http://*:8080/
[cache]
        directory = cache

No Submit button

2 个答案:

答案 0 :(得分:1)

没有问题,一切都按设计工作。仅当更改为“已批准”时,才会显示“提交”按钮。在您的情况下,您需要“Code-Review +2”和“Verified +1”。你只有第一个。点击“回复”按钮并添加“已验证+1”投票,然后将显示“提交”按钮。

注意:您可能无权添加“已验证+1”投票,在这种情况下,您需要首先添加权限。

答案 1 :(得分:0)

gerrit issue 6959中所述:

  

Submit”按钮应显示,如果CL未验证,则可能显示灰色

     

你看到了什么?

     

没有“Submit”按钮   请我解决一下我需要点击“Verified+1

http://www.vogella.com/tutorials/Gerrit/img/xwebreview50.png.pagespeed.ic.8-R3k9h-LU.png