Kemarin saya sempat di buat marah oleh error yang terjadi saat cloning repositori dari remote server. Biasanya saja menggunakan protokol HTTPS untuk proses transaksi data. Karena kurang praktis, akhirnya saya mengubah semua Remote URL repositori saya ke SSH. Sayangnya, saat saya melakukan cloning dari remote server muncul pesan error seperti berikut:
1
2
3
4
5
6
7
8
git clone git@bitbucket.org:emsuryadi/repository.git repo
Cloning into 'repo'...
remote: Counting objects: 638, done.
remote: Compressing objects: 100% (544/544), done.
Connection to bitbucket.org closed by remote host.00 KiB/s
fatal: The remote end hung up unexpectedly
fatal: early EOF
fatal: index-pack failedMatikan kompresi pada saat transfer:
on Linux
Execute the following in the command line before executing the Git command:
export GIT_TRACE_PACKET=1
export GIT_TRACE=1
export GIT_CURL_VERBOSE=1On Windows
Execute the following in the command line before executing the Git command:
set GIT_TRACE_PACKET=1
set GIT_TRACE=1
set GIT_CURL_VERBOSE=1git config --global core.compression 0Selanjutnya, kita lakukan clone parsial untuk mengurangi jumlah data yang diambil:git clone --depth 1 [repo_uri]/[repo_uri]Jika berhasil, masuk ke direktori baru kemudian ambil sisa kloningnya:git fetch --unshallowatau alternatifnya,git fetch --depth=2147483647Selanjutnya, pull seperti biasanya:git pull --allSumber:
