Skip to content

Commit 509dc98

Browse files
committed
Add post about the new git status features in 2.6
1 parent d5cd6d0 commit 509dc98

File tree

1 file changed

+41
-0
lines changed

1 file changed

+41
-0
lines changed
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
---
2+
layout: post
3+
title: "interactive rebase status"
4+
category: intermediate
5+
---
6+
7+
With "git 2.6": https://github.com/git/git/blob/v2.6.0/Documentation/RelNotes/2.6.0.txt it's now easier than ever to keep track of your work during an interactive rebase.
8+
9+
Previously, if you were rebasing interactively and had hit a conflict or stopped to reword a commit, git status would look like this:
10+
11+
<pre>
12+
$ git rebase -i HEAD~5
13+
$ git status
14+
rebase in progress; onto 0927cd6
15+
You are currently rebasing branch 'testbranch' on '0927cd6'.
16+
(fix conflicts and then run "git rebase --continue")
17+
</pre>
18+
19+
This only tells you what branch you started with and the target of your rebase. If you want to get information about which commit you'vestopped on, you need to turn to <pre>git log</pre>.
20+
21+
With the release of 2.6, git status now produces much more helpful output that *reminds you what you were doing*. It includes which rebase commands have finished already, and what's still left to do.
22+
23+
<pre>
24+
$ git rebase -i HEAD~5
25+
$ git status
26+
interactive rebase in progress; onto '0927cd6'
27+
28+
Last commands done (2 done):
29+
pick f47cc4d Style edits
30+
pick 903d58c Post about techcrunch article
31+
edit 8cd01c4 Limit width of post content
32+
33+
Next commands to do (1 remaining commands):
34+
pick 6aa9082 Delete zero-sized files
35+
36+
You are currently editing a commit while rebasing branch 'testbranch' on '0927cd6'.
37+
38+
nothing to commit, working directory clean
39+
</pre>
40+
41+
This gives you more context when working with your commit history, so you know why the rebase stopped.

0 commit comments

Comments
 (0)