gitlab:you are not allowed to push code to protected branches on this project
本地 git 提交已存在的代码到新创建的代码库,然后报错了 you are not allowed to push code to protected branches on this project。经查是因为当前的 gitlab 用户对远程代码库没有操作权限。首先是将当前用户添加到新建代码库的 members 中,并且在提交代码到 master 分支(第一次提交代码会生成 master 分支)