A searchable collection of the most frequently asked Git questions. Following are a couple of my most favorite commands from the list:
-- Commit changes to a new branch
git checkout -b my-new-branch-name
-- Move stashed changes to current branch
git stash apply
Another handy Git command I surely want to see in this list is git commit --amend
which allows adding changes to your last commit.
-- Add changes to last commit
git commit --amend -m "updated commit message"
--amend
flag will tackle situation like:
701c70f Fix issue with api_handler
2e7be87 Update fix to api_handler
7e9f104 Some more fixes to api_handler
16e9747 Last changes to api_handler
3d1e7db This is last change to api_handler
e58043e :(
Thank you!
I appreciate your response on my blog.
It may take a while for your comment to display because I moderate comments to filter out spam and other forms of abuse. Thanks for understanding!