Skip to content

Commit

Permalink
Change command to avoid editing commit message
Browse files Browse the repository at this point in the history
  • Loading branch information
Filipp Pirozhkov committed Nov 12, 2017
1 parent 545a53e commit f60cd9d
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -133,10 +133,11 @@ In order to remove a file from a commit, do the following:
```sh
$ git checkout HEAD^ myfile
$ git add myfile
$ git commit --amend
$ git commit --amend --no-edit
```

This is particularly useful when you have an open patch and you have committed an unnecessary file, and need to force push to update the patch on a remote.
`--no-edit` option is used to keep the existing commit message.

<a name="delete-pushed-commit"></a>
### I want to delete or remove my last commit
Expand Down

0 comments on commit f60cd9d

Please sign in to comment.