我尝试将存储库推送到我的 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/