0

I am trying to do a shallow clone on a large repo and push it to a new destination.

I have done a shallow clone using:

git clone --depth 100 URL

but when I try to push it using:

git push --mirror URL

But I keep getting an error message - "error: failed to push some refs to".

1

1 Answer 1

0

This indicates that another user has pushed a commit to the branch you are pushing to, but that commit hasn't yet arrived on your laptop. This may occur if you haven't recently used "git pull" on a branch with a large number of contributors, like staging. To fix this issue, run:

  1. git pull origin ****your-branch
  2. git push origin ****your-branch
Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.