0

I am using github and I have a few branches made from a backup branch and I am trying to git clone from the sub branch lets call it "x". I have made a lot of changes and pushed them to the "x" branch but now when I git clone, it pulls that branch + the backup branch. Is there a way to only clone from the "x" branch without git cloning its parent branch? On git the "x" branch looks exactly how I want it and some things are deleted that are in the backup branch however git clone sends those deleted files as well. I am a little confused and I hope this is a simple git clone "url" addition. Thank you anyone who knows what I need to do to only clone the "x" branch.

ZachyBear
  • 297
  • 3
  • 15

1 Answers1

0

This is what I had to run.

git clone -b branchName --single-branch https://github.com/clone.url

Hope this helps someone

ZachyBear
  • 297
  • 3
  • 15