git推送到我朋友帐户的新分支

问题描述 投票:0回答:2

我尝试与我的同学一起完成一个项目。我们现在将在同一个 git 存储库上工作,这是我朋友的帐户。我已成功拉取或克隆原始存储库,但无法创建新分支以将更新的文件推送到他的 git 存储库。我有以下错误消息:


remote: Permission to friend/your.git denied to me.
fatal: unable to access 'https://github.com/friend/your.git/': The requested URL returned error: 403

是否有任何设置可以授予我访问我朋友的 git 存储库的权限?还是我的代码错误?

我使用了以下代码:

$ git push origin master:branch
$ git push origin branch
git git-push
2个回答
3
投票

告诉你的朋友去

Repository
|
Settings
|
Collaborators
。然后添加您的电子邮件/用户名作为协作者,授予写入权限。现在您应该获得
Push
许可。


0
投票

454545565634464532123134wdd1223

© www.soinside.com 2019 - 2024. All rights reserved.