Moving uncommitted changes to a new branch [duplicate]

Just create a new branch:

git checkout -b newBranch

And if you do git status you'll see that the state of the code hasn't changed and you can commit it to the new branch.


Just move to the new branch. The uncommited changes get carried over.

git checkout -b ABC_1

git commit -m <message>