Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How can I push a shallow update? Set receive.shallowUpdate on remote?

Tags:

git

bitbucket

I have a project for which I don't have access to the git repository any more. I want to put it in a new repository (on Bitbucket), but when I try to git push -u origin --all I get ! [remote rejected] master -> master (shallow update not allowed) for all branches.

Apparently there is a receive.shallowUpdate config option, but how do I set this on the remote side?

Making an unshallow clone isn't an option, as I don't have access to the original repo.

like image 773
dhuyvetter Avatar asked Jan 26 '16 20:01

dhuyvetter


1 Answers

This error message was introduced in git 1.9.0 with commit 5dbd767, and its test shows that message when pushing commits with grafted root.

If by default the remote side (here BitBucket) has left receive.shallowUpdate to its default value (false), you would need to contact its support.

But first, try and see if applying a git filter-branch -- --all is enough to transform your repo into one you can push directly (because there would be no more graft nodes)

like image 72
VonC Avatar answered Sep 24 '22 06:09

VonC