Skip to content

Instantly share code, notes, and snippets.

Uday K udkl

Block or report user

Report or block udkl

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@udkl
udkl / git-change-commit-messages.md
Created Jul 4, 2016 — forked from nepsilon/git-change-commit-messages.md
How to change your commit messages in Git?
View git-change-commit-messages.md

How to change your commit messages in Git?

At some point you’ll find yourself in a situation where you need edit a commit message. That commit might already be pushed or not, be the most recent or burried below 10 other commits, but fear not, git has your back 🙂.

Not pushed + most recent commit:

git commit --amend

This will open your $EDITOR and let you change the message. Continue with your usual git push origin master.

You can’t perform that action at this time.