經(jīng)過排查,不是因?yàn)闄?quán)限不足,是由于commit提交不規(guī)范引起的提交失敗,報(bào)錯(cuò)如下
limenglin@limenglindeMacBook-Pro acp-web % git push
枚舉對象中: 91, 完成.
對象計(jì)數(shù)中: 100% (91/91), 完成.
使用 8 個(gè)線程進(jìn)行壓縮
壓縮對象中: 100% (50/50), 完成.
寫入對象中: 100% (50/50), 7.92 KiB | 3.96 MiB/s, 完成.
總共 50(差異 34),復(fù)用 0(差異 0),包復(fù)用 0
remote: GitLab: Commit message does not follow the pattern '(?i:^\s*((OCT[\s\S].m*)|((Mod|Fix|Add)\s+[A-Za-z]+-\d+\s+[\s\S].m*)|(Merge[\s\S]*)))'
To git.komect.net:PGCP/acp-web.git
! [remote rejected] lml_dev_20220825 -> lml_dev_20220825 (pre-receive hook declined)
error: 推送一些引用到 'git.komect.net:PGCP/acp-web.git' 失敗
修改commit信息,用下面這行命令就行文章來源:http://www.zghlxwxcb.cn/news/detail-533409.html
git commit --amend -m 'OCT: 刪除無用變量代碼'
然后重新push,就成功了文章來源地址http://www.zghlxwxcb.cn/news/detail-533409.html
limenglin@limenglindeMacBook-Pro acp-web % git push
枚舉對象中: 91, 完成.
對象計(jì)數(shù)中: 100% (91/91), 完成.
使用 8 個(gè)線程進(jìn)行壓縮
壓縮對象中: 100% (50/50), 完成.
寫入對象中: 100% (50/50), 7.92 KiB | 2.64 MiB/s, 完成.
總共 50(差異 34),復(fù)用 0(差異 0),包復(fù)用 0
remote:
remote: To create a merge request for lml_dev_20220825, visit:
remote: http://git.komect.net/PGCP/acp-web/merge_requests/new?merge_request%5Bsource_branch%5D=lml_dev_20220825
remote:
To git.komect.net:PGCP/acp-web.git
ef64912a..506c66e2 lml_dev_20220825 -> lml_dev_20220825
到了這里,關(guān)于【問題記錄】git報(bào)錯(cuò):[remote rejected] (pre-receive hook declined)的文章就介紹完了。如果您還想了解更多內(nèi)容,請?jiān)谟疑辖撬阉鱐OY模板網(wǎng)以前的文章或繼續(xù)瀏覽下面的相關(guān)文章,希望大家以后多多支持TOY模板網(wǎng)!