git - Creating branch to uncommitted works -
I cloned for remote repo and started working on code. I have not created any commitments / commitments / so far till I add, modify and delete the code. Now I do not want to push these changes in the remote repo because I have to complete all related work. At the same time, I need to try different ways too. I can save current changes in "new branch" without losing my work, then create new branch and start working on one of those branches Do it
In the end I have the idea of doing something like this:
Master ---> donesofar -> trynew
You can create a new branch, and submit the code to it, and then create another new branch to do the job.
git checkout -b donsafer git add & amp;; & Amp; Git commit -m "msg" git checkout -b trynew
Now, you will be on a branch trynew
, where all your changes will be donesofar < Changes in / code> are going to be preserved because you are not working on them anymore.
Comments
Post a Comment