17 lines
428 B
Markdown
17 lines
428 B
Markdown
---
|
|
title: Change your commit message for the most recent commit
|
|
---
|
|
|
|
If you've made a typo or have another reason why you'd like to
|
|
change the most recent commit message, you run this command:
|
|
|
|
```bash
|
|
git commit --amend
|
|
```
|
|
|
|
If you run it like this, it will spin up your predefined editor.
|
|
To specify the updated commit message on the command line, run:
|
|
|
|
```bash
|
|
git commit --amend -m "This is my improved commit message"
|
|
```
|