首页 > 解决方案 > 不支持的压缩,Azure git push over SSH?

问题描述

我正在尝试将一个新分支推送到失败的 azure repo。收到不支持压缩方法的错误。尝试用谷歌搜索错误,但我的搜索没有显示任何看起来相同的问题。

PS C:\dev\vh> git push --set-upstream origin upgrade/2019-12-12_Merged-HC_Development_to_hc
Counting objects: 67, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (41/41), done.
remote: The archive entry was compressed using an unsupported compression method.
fatal: The remote end hung up unexpectedly
fatal: sha1 file '<stdout>' write error: Broken pipe
error: remote unpack failed: error The archive entry was compressed using an unsupported compression method.
error: failed to push some refs to 'git@ssh.dev.azure.com:v3/vh/VHT/VHT'

试图找到在 ssh url 上创建此分支的解决方案。如果我将推送 URL 更改为 https 而不是 ssh,则效果很好。因此,非常感谢关于我应该在哪里寻找答案的建议,或者如果您有解决方案通过 git cli 将新创建的分支推送到 Azure 存储库。

标签: gitazureazure-devopsazure-repos

解决方案


将存储库从 gitlab 移动到客户端的 vsts 时出现此错误。我设法通过运行来解决它而无需切换SSHHTTPS

  1. git gc在我的克隆中执行垃圾收集
  2. git remote prune origin清理任何过时的分支引用

然后重试git push vsts --all.

vsts指的是我的新 vsts 存储库的远程名称。 origin指向我的 gitlab 存储库。


推荐阅读