0

I have been told that development takes place in the "testing" branch of some XYZ git tree:

https://git.develop.org/def/pqr/abc/xyz.git/

The above link is an imaginary/hypothetical git link related to Linux kernel.

So how do I clone the testing branch on my local laptop? Will the following command suffice?:

git clone https://git.develop.org/def/pqr/abc/xyz.git/

What if it clones another branch ? for example master. Do i need to change to testing branch explicitly using git checkout ...

OR is there any other command to clone the testing branch directly ?

Martijn Pieters
  • 1,048,767
  • 296
  • 4,058
  • 3,343
  • https://stackoverflow.com/search?q=%5Bgit%5D+clone+branch – phd Mar 07 '20 at 14:33
  • " I have been told that development takes place in the "testing" branch of some XYZ git tree" .. well, it depends of each project politic, it's not an absolute rule – Mali Mar 07 '20 at 16:02

1 Answers1

0

Just use this command:

git clone -b <branch> <remote_repo>

more

Ilya Tatsiy
  • 185
  • 2
  • 8