在开发项目的时候,打了几个分支,却换分支提交代码的时候Gitlab提示这样的错误信息:
hook declined
GitLab: You are not allowed to access v1.0!
error: hook declined to update refs/heads/v1.0
GitLab: You are not allowed to access v1.0!
error: hook declined to update refs/heads/v1.0
这个问题主要是由于git工程里的hooks/post-receive和update引起的。可以删除这两个文件,如果没有的话把update的软连接 ls -s给删除掉,这样就可以成功的提交代码了!
原因:
软链接链错了位置