Skip to content

Commit 56c958d

Browse files
committed
Adding git reset --soft HEAD~
1 parent b759b8d commit 56c958d

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

README.md

+5
Original file line numberDiff line numberDiff line change
@@ -181,6 +181,11 @@ This will give you an interface on your core editor:
181181
# s, squash = use commit, but meld into previous commit
182182
# f, fixup = like "squash", but discard this commit's log message
183183
# x, exec = run command (the rest of the line) using shell
184+
185+
# Squashing commits together using reset --soft
186+
$ git reset --soft HEAD~number_of_commits
187+
$ git commit
188+
** WARNING: this will require force pushing commits, which is OK if this is on a branch before you push to master or create a Pull Request.
184189
```
185190
186191
#### Branching and merging

0 commit comments

Comments
 (0)