maindrop-00113 lines mergedscoreboardmade to order · ships in about a week
vibetokens

50 jokes · git log · all original

Funny Git Commit Messages

Funny git commit messages are the honest ones: “fix typo” on a change to 412 files, or “wip” as the only message on a branch that shipped. These 50 are original, written for this page, and each is a commit message you have seen, or written.

A commit message is a note to a stranger: you, eight months from now, running git blame at the worst possible moment. Most of the messages below would not help that stranger. That is the joke.

None of them comes from a real repository, though you may recognize a few from your own history. Each one is the message first, then what the diff actually did.

Read in order, they tell the story of most branches: a small change that was not small, a run of wip, a merge that went sideways, a rebase to tidy it up and a revert at the end of the week. If that is your branch, the guide at the bottom has the fix, and it takes about a minute per commit.

01 Small words · 10 jokes

Small messages, large diffs

The shorter the message, the bigger the change. Nobody wrote this rule down. It is just what git log shows, every time, on every team. It is also one of the best arguments for squash and merge, which lets one well-written message stand in for all of these.

  1. 01fix typo 412 files changed, 9,871 deletions.
  2. 02minor cleanup Removed the payments module.
  3. 03small tweak Moved the database from one Postgres to a different Postgres.
  4. 04update Updated what, the history will never say.
  5. 05refactor Same behavior, as far as anyone can tell, which is not very far.
  6. 06misc The most honest word in the repository.
  7. 07formatting Also changed the pricing logic, inside the formatting.
  8. 08. A single period. Committed with total confidence.
  9. 09address feedback Addressed it by deleting the test the reviewer commented on.
  10. 10bump deps 214 dependencies, three major versions each.

02 The sequel · 10 jokes

wip, final, final final

Every branch has a story, and the commit messages are the chapter titles. These are the ones from the middle, where the author is sure it is almost done and CI is not. The one last commit is never the last one, and the messages get shorter as the evening gets longer.

  1. 11wip Merged to main as wip. Still wip, technically.
  2. 12wip 2 The sequel. Darker than the original.
  3. 13ok actually fixed It was not.
  4. 14ok actually actually fixed CI was red for a reason unrelated to the word actually.
  5. 15final Followed by seven more commits.
  6. 16final final Pushed with the energy of someone saving a file as report_v3_USE_THIS.
  7. 17last one I promise There were four more. The promise was made in good faith.
  8. 18please work It worked. Nobody knows which change did it.
  9. 19trying something The something is still in production.
  10. 20Revert "trying something" Reverted the code. The migration stayed.

03 Merges · 10 jokes

Merge messages nobody reads

A merge conflict is two correct changes that need an editor. The commit message is where the editor explains what they did, usually in three words, usually after midnight, and usually without mentioning which side won.

  1. 21Merge branch 'main' of origin into main The most common message in the repository, and the least read.
  2. 22resolve conflicts Resolved by keeping both versions, one under the other.
  3. 23fix bad merge The bad merge was the one called resolve conflicts.
  4. 24accept incoming For all 63 files. Did not open any of them.
  5. 25accept current The same 63 files, in the other direction, an hour later.
  6. 26remove conflict markers Missed one. The settings page now ends with >>>>>>> main.
  7. 27sync with main Fourth time today. The branch is mostly syncing now.
  8. 28merge my changes into my other changes Two laptops, one person, no plan.
  9. 29undo merge of the undo A revert of a revert of a merge. Bisect has stopped answering.
  10. 30resolve conflict in package-lock.json Resolved by deleting it and running install. A classic, and a mystery.

04 Rewriting history · 10 jokes

Rebase, force push, regret

To rebase is to rewrite history, which is the one thing most people would like to do with their commit messages. These are the messages that survived the rewrite anyway, plus a few written during it by someone who had just learned what the reflog is.

  1. 31rebase onto main Took 40 minutes. The diff is identical. Every commit has a new ID, like a witness protection program.
  2. 32force push With --force, not --force-with-lease. A teammate's afternoon went with it.
  3. 33apply suggestions from code review All 22 of them, in 22 commits, each with this message.
  4. 34squash me Nobody did. It is on main now, asking forever.
  5. 35undo rebase There is no undo rebase. There is the reflog, and a long, quiet hour.
  6. 36rebased again Main moved while I was rebasing. Main is always moving.
  7. 37clean up history The cleaned-up history has more commits than before.
  8. 38resolve rebase conflicts (14 of 14) It was the same conflict 14 times. rerere was not enabled.
  9. 39update branch Clicked the Update branch button. The build broke in a new and educational way.
  10. 40sorry Pushed straight to main. The message is the whole apology, and it is accurate.

05 After hours · 10 jokes

Friday, late night and the revert

Some commit messages are timestamps more than descriptions. You can tell the hour from the punctuation. When a branch is not ready, the safe label is do not merge, and even that one gets merged.

  1. 41do not merge Merged. The warning was in the title, which nobody reads.
  2. 42quick fix before the weekend Committed Friday at 4:58 PM. The weekend was not quick.
  3. 43it works now Does not say where. The answer is one laptop.
  4. 44Revert "quick fix before the weekend" Committed Saturday morning, from a phone.
  5. 45I am so tired Changed one line. It was the right line.
  6. 46temporary Added three years ago. Load-bearing now.
  7. 47add debug logging, remove later Later has not arrived. The logs are most of the storage bill.
  8. 48hotfix The fourth hotfix this week, each one fixing the one before.
  9. 49why does this work Committed as a question. Nobody has answered it, and nobody touches the file.
  10. 50ship it Committed at 11:47 PM by someone who has since logged off for the week.

How to write a commit message you will not regret

Write the subject in the imperative, the way you would finish the sentence “this commit will...”: “Add retry to the payment webhook,” not “fixed stuff.” Keep it to about 50 characters so it fits in git log and on GitHub.

Leave a blank line, then write the body for the stranger running git blame in eight months. Say why the change was needed and what you considered. The diff already says what changed.

Make one change per commit where you can. If the branch history is mostly wip, clean it up with an interactive rebase before review, or let squash and merge fold it into one commit with a message you edit by hand.

Reference the issue or ticket in the body, not only in the branch name. Branch names disappear after the merge. The commit stays, and so does the link.

Never put a secret in a commit message, or in a commit. Removing it later means rewriting history and rotating the secret anyway.

And read your own log now and then. git log --oneline on the last week of main is the fastest way to see whether your team's messages would help anyone, including you.

If your own git log reads like this page, you are in good company, and the fix is short: one change per commit, a subject that says what changed, a body that says why. For the teammate whose history is mostly wip, the gift guide for programmers has the line they already type.

06 The plain answers

Questions.

What makes a good git commit message?
A short subject line, about 50 characters, that says what the commit does in the imperative mood, like “Add retry to the payment webhook.” Then a blank line and a body that explains why the change was needed, wrapped at about 72 characters.
What does “wip” mean in a commit message?
Work in progress. It marks a commit that saves unfinished work, usually on a branch that will be cleaned up before review. Many teams squash these commits before they reach the main branch.
How do I change my last commit message?
Run git commit --amend and edit the message. If you already pushed the commit, the push has to replace the remote branch, so use git push --force-with-lease, and only on a branch nobody else is building on. Rebase and force push, explained →
Should I squash commits before merging?
Many teams do, so each change lands on the main branch as one commit with one readable message. The trade-off is that the individual steps from the branch no longer appear in the main history. Squash and merge in the dictionary →

More jokes

Keep reading.