How to clone all remote branches in Git

0 votes

Hi Guys,

I have one Github repository. In this repo, I have multiple branches. I want to clone all the branches in the local Git. How can I do that?

Sep 4, 2020 in Git & GitHub by akhtar
• 38,260 points
1,405 views

1 answer to this question.

0 votes

Hi@akhtar,

You can use the git clone command to your local Git. It will clone the whole repo to your system as shown below.

$ git clone git://account_name/reponame
$ cd reponame

To see all branches, you can use the command.

$ git branch -a
answered Sep 4, 2020 by MD
• 95,460 points

Related Questions In Git & GitHub

0 votes
1 answer

How to add a remote git repository in Jenkins

Follow these steps: Step 1 Go to Manage ...READ MORE

answered May 23, 2019 in Git & GitHub by Alok
13,692 views
0 votes
1 answer

How to list all the files in a commit in Git?

Hi@akhtar, Using git diff-tree is considered as a preferred way ...READ MORE

answered Dec 22, 2020 in Git & GitHub by MD
• 95,460 points
1,040 views
0 votes
1 answer

How to do a re-merge into another branch in git

Seems like you want to rebase your ...READ MORE

answered May 7, 2018 in Git & GitHub by DareDev
• 6,890 points
2,472 views
0 votes
1 answer
+15 votes
2 answers

Git management technique when there are multiple customers and need multiple customization?

Consider this - In 'extended' Git-Flow, (Git-Multi-Flow, ...READ MORE

answered Mar 27, 2018 in DevOps & Agile by DragonLord999
• 8,450 points
4,062 views
+2 votes
1 answer
0 votes
1 answer

How to list all the saved stashes in Git?

Hi@akhtar, In Git, the stash operation takes your ...READ MORE

answered Nov 20, 2020 in Git & GitHub by MD
• 95,460 points
648 views
0 votes
1 answer

How to delete all the Git stashes in the stack?

Hi@akhtar, If you want to delete all the ...READ MORE

answered Nov 20, 2020 in Git & GitHub by MD
• 95,460 points
1,177 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP