I am working on a project using Git as the VCS. I got a branch xyz cut from the mainline branch of master. After working for a while, I committed my code and took a
xyz
as long as you did not commit you can type
git merge --abort
just as the command line suggested.