I was working on my Rails project which is checked into Git. I read tutorials and they said for every time you start to change something, check out a branch.
However, accidentally I made some changes but did not check out a branch.
What should I do now?
What commands can I run so that Git takes my new changes and push them on my repository?
Of course, if your changes are already on the branch you’re going to put them on, just commit and go with it.
I hope you added a commit into jkp’s answer. I can see somebody running that exact sequence without doing a commit and thus wiping out all their uncommitted changes…