ปกติ ถ้าเรา run git clone จะได้ branch default ( หากไม่มีการเปลี่ยน default branch name ก็จะได้ branch main )
bash
git clone [email protected]:abc/first-repo.git
แต่ถ้าหากอยากระบุ branch ตอนที่ สั่ง git clone ก็สามารถทำได้โดยระบุชื่อ ด้วย parameter -b
เช่น ต้องการ clone branch name test
bash
git clone -b test [email protected]:abc/first-repo.git