我有本地工作副本SourceTree。和所有的操作工作得很好,我可以简单的获取,推,拉等通过SourceTree。我只需要在SourceTree中不存在的force push。
我打开终端使git按-f
remote: Repository not found.
fatal: repository 'https://github.com/MyRepo/project.git/' not found
我不确定会有什么问题。
我有本地工作副本SourceTree。和所有的操作工作得很好,我可以简单的获取,推,拉等通过SourceTree。我只需要在SourceTree中不存在的force push。
我打开终端使git按-f
remote: Repository not found.
fatal: repository 'https://github.com/MyRepo/project.git/' not found
我不确定会有什么问题。
当前回答
在我的情况下,我不能克隆github由于用户是错误的。
转到~/.gitconfig 然后尝试删除这行代码(只需删除它,然后保存文件)。
[user]
name = youruser
email = youruser@domain.com
或者尝试在CMD或终端中使用一行代码:git config——global——remove-section user
并尝试再次做git克隆。希望它能帮你度过美好的一天。><
其他回答
这里的问题是你的本地git无法将更改推送到远程 检查你的遥控器是否设置正确
git remote -v
如果没有正确设置,请尝试将您的遥控器设置为
git remote set-url origin https://username@github.com/MyRepo/project.git
然后尝试使用
git push -u origin master
也有可能你的本地git有不同的凭据,请检查一下。
所以你的url当前看起来如下所示
https://github.com/RevanthM/Log_Monitoring
它应该是这样的
https://RevanthM@github.com/RevanthM/Log_Monitoring
不同的是,在url的开头,我添加了我的github用户名,后面跟着一个@符号。
操作系统
使用VS Code和一个没有密码的密钥:
removed eval "$(ssh-agent -s)" line from my ~/.zshrc file to stop running it in the background (first step on Github's Generating a new SSH key article) verified my .ssh/config entry for *.github.com did not have a UseKeychain line used simply ssh-add ~/.ssh/id_ed25519 with NO --apple-use-keychain on VS Code "Git: Add remote..." allowed/authorized my Github account connection (you don't really need to add a remote) applies a new "vscodevscode.github-authentication" entry in Mac's Keychain Access app closed all shells and VS Code, restarted and the repo is now always found
此消息可以在找到存储库时发生,但我们没有提交访问权。不是措辞巧妙的!
在克隆了老板为我创建的gitHub存储库后,我收到了repo-not-found消息。我可以在本地复制和提交,但不能向上推提交。存储库所有者没有给我写权限。通过请求对回购所有者的写访问来解决。
在我的情况下,我需要在Linux上使用Ctrl + H打开目录来查看隐藏的文档,所以我进入Git配置并在URL中取出。Git。