# Editing the Last Commit

If not all the changes should go into the commit, we can do a `Mixed` reset to the previous commit and redo the commit with only the wanted changes.

![](https://1560106033-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LS9bmsupx6ftQfO0PH7%2F-LS9fAHqNxdACSicbwz0%2F-LS9fneh6DsQaKtX2SoL%2Fimage.png?alt=media\&token=8a546b49-eb68-4a44-8f3b-805377e506f3)

Commandl line:

```
git reset HEAD~
# add only the wanted file 
# or use interactive add to add some portions of the file
git add awesome_changes.txt 
git commit
```
