Reputation: 177
Say I have so far only worked on master
and already pushed all the commits to the master
branch on github.com. It is that simple to create a testing
with all the content from master
(at this specific point in time)?
$ git checkout -b testing
$ git add *
$ git push origin testing
Upvotes: 0
Views: 878
Reputation: 2681
Yes, as RomainValeri says, it is not necessary the git add *
To create the testing branch, if you are in the master branch:
git checkout -b testing
To push your modifications to the branch testing:
git add -A
git commit -m "Some message"
git push origin testing
Then, if your are want to merge what you have in testing to the master branch:
git checkout master
git merge testing
Upvotes: 1