git - 致命: protocol '' https' is not supported in Git

标签 git azure github

我尝试将存储库推送到我的 azure通过 runnng 远程 git push azure master 。远程 URL 为 'https://<myid>@ndas.scm.azurewebsites.net/<myapp>.git' .

问题是,它说不支持协议(protocol)“https”

请参阅以下屏幕截图:

最佳答案

The problem is, it says protocol 'https' is not supported

实际上没有这么说。它实际上是这样说的:

fatal: protocol ''https' is not supported

请注意开头的两个单引号和结尾的一个单引号。第一个和最后一个引用了错误消息的协议(protocol),但第二个引用是被拒绝的协议(protocol)的一部分:'https .

另请注意您在 git remote -v 中看到的完整输出。您的azure远程 URL 包含文字前导和尾随单引号,而您的 origin远程 URL(可能有效)则不起作用。

尝试运行

git remote set-url azure https://<a href="https://stackoverflow.com/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="a5d5cacac8c4cbcc9c9de5cbc1c4d68bd6c6c88bc4dfd0d7c0d2c0c7d6ccd1c0d68bcbc0d1" rel="noreferrer noopener nofollow">[email protected]</a>/ndas.git

将远程 URL 设置为 https://<a href="https://stackoverflow.com/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="a5d5cacac8c4cbcc9c9de5cbc1c4d68bd6c6c88bc4dfd0d7c0d2c0c7d6ccd1c0d68bcbc0d1" rel="noreferrer noopener nofollow">[email protected]</a>/ndas.git而不是'https://<a href="https://stackoverflow.com/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="6d1d0202000c030454552d03090c1e431e0e00430c17181f081a080f1e0419081e43030819" rel="noreferrer noopener nofollow">[email protected]</a>/ndas.git' ,然后再次 push 。

关于git - 致命: protocol '' https' is not supported in Git,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/53012197/

相关文章:

reactjs - gh-pages 脚本无法将 .nojekyll 提交到 GitHub

c# - 如何浏览Service Fabric上的应用程序?

git - refs/pull/*/head -> origin/pr/* 出现在 git pull

python - "ModuleNotFoundError"与使用 Python 的 Azure 函数应用程序

Azure AD B2C - 我们可以限制 adb2c 中用户的并发登录吗?

github - 如何在 Kubernetes dockerconfigjson 中使用 Github 包 Docker 注册表?

mysql - 有没有一种方便的方法可以在我的 git 提交中包含一个 mysqldump?

git - 为什么我的 .gitattributes 文件不能在我的 Mac 上运行?

macos - 无法使用 Homebrew 安装 Git

linux - 在 bash 中使用 EOF 获取 FOR 的输出