通过HTTP失败提取大型存储库(大小超过1GB) [英] Pull large repository (more than 1GB size) over http fail
问题描述
存储库的大小超过1GB,当我上拉至50%时,发生了错误:
The repository's size is over 1GB, when i pull up to 50%, error occurred:
> remote: Counting objects: 23891, done. remote: Compressing objects:
> 100% (19980/19980), done. fatal: The remote end hung up
> unexpectedly3.61 MiB | 333 KiB/s fatal: early EOF fatal: recursion
> detected in die handler
请问有人可以帮我吗?
推荐答案
由于存储库的大小,它很可能会失败.
It will most likely fail due to the size of your repository.
如果您有权访问远程存储库, 试试这个:
If you have access to the remote repository, try this:
- 获取远程存储库文件的副本.您可以tar.gz远程存储库目录并将其下载到本地计算机.
- 将远程存储库解压缩到本地计算机中的某个位置.
-
从您的计算机克隆存储库(此处没有文件下载,因此应该可以正常工作)
- Get a copy of the remote repository files. You can tar.gz the remote repository directory and download it to your local machine.
- Unzip the remote repository somewhere in your local machine.
Clone the repository from your machine (no file downloading here so it should work)
git clone/path/to/where/you/unzip/the/remote/repository your_local_copy
git clone /path/to/where/you/unzipped/the/remote/repository your_local_copy
编辑您可以在"your_local_copy"目录中找到的.git/config文件
Edit the .git/config file you can find inside 'your_local_copy' directory
编辑[remote"origin"]行下面的'url'键的值.
Edit the value of the 'url' key just below the [remote "origin"] line.
[远程来源"]
url = git + ssh://youruser@yourrepositoryhost/srv/git/yourrepository.git
url = git+ssh://youruser@yourrepositoryhost/srv/git/yourrepository.git
您的本地存储库现在将指向远程存储库,并且应该可以正常工作.
Your local repository will now point to the remote repository and should work as expected.
这篇关于通过HTTP失败提取大型存储库(大小超过1GB)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!