From: Johannes Schindelin Date: Thu, 26 Jan 2017 16:08:41 GMT Subject: [PATCH v2 1/1] status: be prepared for not-yet-started interactive rebase Message-ID: In-Reply-To: Some developers might want to call `git status` in a working directory where they just started an interactive rebase, but the edit script is still opened in the editor. Let's show a meaningful message in such cases. Signed-off-by: Johannes Schindelin --- t/t7512-status-help.sh | 19 +++++++++++++++++++ wt-status.c | 14 ++++++++++---- 2 files changed, 29 insertions(+), 4 deletions(-) diff --git a/t/t7512-status-help.sh b/t/t7512-status-help.sh index 5c3db656df..458608cc1e 100755 --- a/t/t7512-status-help.sh +++ b/t/t7512-status-help.sh @@ -944,4 +944,23 @@ EOF test_i18ncmp expected actual ' +test_expect_success 'status: handle not-yet-started rebase -i gracefully' ' + ONTO=$(git rev-parse --short HEAD^) && + COMMIT=$(git rev-parse --short HEAD) && + EDITOR="git status --untracked-files=no >actual" git rebase -i HEAD^ && + cat >expected <