Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 592011
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T15:41:41+00:00 2026-05-13T15:41:41+00:00

I am having great success with git push –mirror to make backup copies to

  • 0

I am having great success with git push --mirror to make backup copies to a bare repo. But after search on SO and elsewhere, I cannot find a way to clone the thing locally with all branches. I do not want to use git clone since I don’t want my local repo to know about the bare repo. If I use git pull it only brings down the HEAD branch.

Guessing:

git pull /data/Dropbox/backup/that_stuff.git *

gets me nowhere, of course.

How do I get the entire repo with all branches back again? I realize I could probably just copy the bare repo to my .git directory, but that seems like a bad idea.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-13T15:41:42+00:00Added an answer on May 13, 2026 at 3:41 pm

    Try git fetch instead of git pull

    Since git pull is there to fetch a branch and merge it to a local branch, it wouldn’t make alot of sense trying to merge all remote branches to a local branches.

    $ git fetch a-repo_url
    

    The above command copies all branches from the remote refs/heads/ namespace and stores them to the local refs/remotes/remoteRpo/ namespace, unless the branch.<name>.fetch option is used to specify a non-default refspec..
    Try:

    $ git fetch a-repo-url +refs/heads/*:refs/heads/*
    

    could force fetching all heads for all branches.
    See this SO question.


    The OP yar reports:

    git pull /data/Dropbox/backup/mjdj.git/ +refs/heads/*:refs/heads/*
    

    works.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I've been using Spring JDBC with great success but I am having alot of
I'm using XSLT and having great success, just got a couple of problems. Warning:
Good morning! I'm having great success so far with CodeIgniter. I'm new to PHP
I have used this site before with great success and I am having a
I am having great success getting the look I want using a custom header
I'm using ASP.NET charts for the first time and am having great success. The
I am having great difficulty reading the API for named scopes. Each bid has
We're having great results with the Phusion stack ( Passenger and Ruby Enterprise Edition
I'm having great trouble in converting the following SQL to LINQ to SQL, any
I'm having great difficulty getting my Android application to play videos from the SD

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.