>_ IzzyLab

Topic breakdown

git commit --amend doesn't add a new commit, it rewrites the most recent one: it replaces the branch tip with a new object (with a new hash), keeping the contents. If the index is empty, only the metadata changes — for example the message text — while the files stay untouched. That's why the total commit count doesn't grow, which is what distinguishes amend from an ordinary git commit.

What's checked

  1. last commit's message is Fix login bug
  2. commit count is unchanged
  3. the commit's contents are unchanged

What it looks like