Skip to content

Commit

Permalink
Merge branch 'toptal-more-specific-removal-of-a-file-from-commit'
Browse files Browse the repository at this point in the history
  • Loading branch information
RichardLitt committed Nov 12, 2017
2 parents 103e920 + 186ed0a commit a38b385
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -133,11 +133,11 @@ In order to remove a file from a commit, do the following:

```sh
$ git checkout HEAD^ myfile
$ git add -A
$ git commit --amend
$ git add myfile
$ 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.
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. The `--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 a38b385

Please sign in to comment.