git - cloning a remote branch results in cloning all remote branches...why? -
for reason keep on cloning remote branches when want clone specific remote branch.
i've google , search in 1 can't seem find it. i'm trying clone remote branch, say:
git clone https://github.com/whatever --branch foo once finished, if check branches:
git branch -a i can see list of remote branches...maybe got wrong...but how can clone specific branch only? don't want/need others...any idea?
thanks
use --single-branch option:
git clone https://github.com/whatever --branch foo --single-branch <folder>
Comments
Post a Comment