I am using git on a relatively small project and I find that zipping the .git directory\'s contents might be a fine way to back up the project. But this is kind of weird bec
came to this question via google.
Here is what i did in the simplest way.
git checkout branch_to_clone
then create a new git branch from this branch
git checkout -b new_cloned_branch
Switched to branch 'new_cloned_branch'
come back to original branch and continue:
git checkout branch_to_clone
Assuming you screwed up and need to restore something from backup branch :
git checkout new_cloned_branch -- #notice the space before and after "--"
Best part if anything is screwed up, you can just delete the source branch and move back to backup branch!!