You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Your branch is up to date with 'origin/your-contribution'.
172
172
```
173
-
174
-
2. Start an interactive rebase using a specific commit hash, or count backwards from your last commit using `HEAD~<n>`, where `<n>` represents the number of commits to include in the rebase.
173
+
174
+
2. Start an interactive rebase using a specific commit hash, or count backwards from your last commit using `HEAD~<n>`, where `<n>` represents the number of commits to include in the rebase.
# e, edit <commit> = use commit, but stop for amending
193
193
# s, squash <commit> = use commit, but meld into previous commit
194
194
# f, fixup <commit> = like "squash", but discard this commit's log message
195
-
195
+
196
196
...
197
-
197
+
198
198
```
199
199
200
-
3. Use a command line text editor to change the word `pick` to `fixup` for the commits you want to squash, then save your changes and continue the rebase:
200
+
3. Use a command line text editor to change the word `pick` to `fixup` for the commits you want to squash, then save your changes and continue the rebase:
201
201
202
202
```
203
203
pick 2ebe926 Original commit
204
204
squash 31f33e9 Address feedback
205
205
pick b0315fe Second unit of work
206
-
206
+
207
207
...
208
-
208
+
209
209
```
210
-
211
-
Output (after saving changes) is similar to:
212
-
210
+
211
+
Output (after saving changes) is similar to:
212
+
213
213
```
214
214
[detached HEAD 61fdded] Second unit of work
215
215
Date: Thu Mar 5 19:01:32 2020 +0100
216
216
2 files changed, 15 insertions(+), 1 deletion(-)
217
-
217
+
218
218
...
219
-
219
+
220
220
Successfully rebased and updated refs/heads/master.
221
221
```
222
222
4. Force push your changes to your remote branch:
@@ -231,7 +231,7 @@ masse. This makes reviews easier.
231
231
232
232
### Merging a commit
233
233
234
-
Once you've received review and approval, your commits are squashed, your PR is ready for merging.
234
+
Once you've received review and approval, your commits are squashed, your PR is ready for merging.
235
235
236
236
Merging happens automatically after both a Reviewer and Approver have approved the PR. If you haven't squashed your commits, they may ask you to do so before approving a PR.
0 commit comments