git - 无法 curl git 标签

标签 git curl git-tag

我想通过命令行 curl 一个 git 标签:

curl -O http://someurl

但是当我尝试解压文件时它坏了?有谁知道问题出在哪里?

最佳答案

您可以从 GitHub 等 git repos 托管服务curl 一个 git 标签,因为它有一个 dedicated tarball service (如 Nodeload )提供 tar(或 zip)。但没有任何其他 git 存储库提供相同的服务。

有关 GitHub 的具体示例,请参阅“Having trouble downloading Git archive tarballs from Private Repo ”(或此 curl GitHub tutorial ):

curl -sL --user "${username}:${password}" https://github.com/$account/$repo/tarball/$tag_name > tarball.tar

public repo 上:

curl -L https://github.com/pinard/Pymacs/tarball/v0.24-beta2 | tar zx

关于git - 无法 curl git 标签,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/14101317/

相关文章:

git - 检查 Git 标签导致 "detached HEAD state"

git - 由于特殊字符 "Ã",无法删除 GIT 标签

git - 使用经典 UI 在 Jenkins 管道上配置 git 超时

git - 检测本地和远程之间不同步的所有标签

混帐配置 : bad config for shell command

php - 在通过 HTTP 下载数据之前确定文件大小

android - 使用 cURL 调用 Firebase Cloud Messaging 时出现 "Request had invalid authentication credentials"

c++ - curl 多接口(interface)不起作用

git - 使用 maven-release-plugin 标记和提交非源

git - 无法从 ubuntu 中的 bitbucket 克隆 git 存储库