summaryrefslogtreecommitdiff
path: root/t/t7508-status.sh
diff options
context:
space:
mode:
authorJohn Lin <johnlinp@gmail.com>2019-06-04 14:02:21 (GMT)
committerJunio C Hamano <gitster@pobox.com>2019-06-21 15:54:05 (GMT)
commitb2f5171ecc2feb4192acd80f5a6b05c06e099e97 (patch)
treee2bfb731d326b918cc434e63c80f82352d35ed06 /t/t7508-status.sh
parent97ed685701a6df0273f7d29fd5bc0a0658a63cad (diff)
downloadgit-b2f5171ecc2feb4192acd80f5a6b05c06e099e97.zip
git-b2f5171ecc2feb4192acd80f5a6b05c06e099e97.tar.gz
git-b2f5171ecc2feb4192acd80f5a6b05c06e099e97.tar.bz2
status: remove the empty line after hints
Before this patch, there is inconsistency between the status messages with hints and the ones without hints: there is an empty line between the title and the file list if hints are presented, but there isn't one if there are no hints. This patch remove the inconsistency by removing the empty lines even if hints are presented. Signed-off-by: John Lin <johnlinp@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t7508-status.sh')
-rwxr-xr-xt/t7508-status.sh62
1 files changed, 0 insertions, 62 deletions
diff --git a/t/t7508-status.sh b/t/t7508-status.sh
index 681bc31..4e676cd 100755
--- a/t/t7508-status.sh
+++ b/t/t7508-status.sh
@@ -95,18 +95,15 @@ test_expect_success 'status --column' '
#
# Changes to be committed:
# (use "git restore --staged <file>..." to unstage)
-#
# new file: dir2/added
#
# Changes not staged for commit:
# (use "git add <file>..." to update what will be committed)
# (use "git restore <file>..." to discard changes in working directory)
-#
# modified: dir1/modified
#
# Untracked files:
# (use "git add <file>..." to include in what will be committed)
-#
# dir1/untracked dir2/untracked
# dir2/modified untracked
#
@@ -129,18 +126,15 @@ cat >expect <<\EOF
#
# Changes to be committed:
# (use "git restore --staged <file>..." to unstage)
-#
# new file: dir2/added
#
# Changes not staged for commit:
# (use "git add <file>..." to update what will be committed)
# (use "git restore <file>..." to discard changes in working directory)
-#
# modified: dir1/modified
#
# Untracked files:
# (use "git add <file>..." to include in what will be committed)
-#
# dir1/untracked
# dir2/modified
# dir2/untracked
@@ -279,23 +273,19 @@ and have 1 and 2 different commits each, respectively.
Changes to be committed:
(use "git restore --staged <file>..." to unstage)
-
new file: dir2/added
Changes not staged for commit:
(use "git add <file>..." to update what will be committed)
(use "git restore <file>..." to discard changes in working directory)
-
modified: dir1/modified
Untracked files:
(use "git add <file>..." to include in what will be committed)
-
dir2/modified
Ignored files:
(use "git add -f <file>..." to include in what will be committed)
-
.gitignore
dir1/untracked
dir2/untracked
@@ -348,18 +338,15 @@ and have 1 and 2 different commits each, respectively.
Changes to be committed:
(use "git restore --staged <file>..." to unstage)
-
new file: dir2/added
Changes not staged for commit:
(use "git add <file>..." to update what will be committed)
(use "git restore <file>..." to discard changes in working directory)
-
modified: dir1/modified
Ignored files:
(use "git add -f <file>..." to include in what will be committed)
-
.gitignore
dir1/untracked
dir2/modified
@@ -421,13 +408,11 @@ and have 1 and 2 different commits each, respectively.
Changes to be committed:
(use "git restore --staged <file>..." to unstage)
-
new file: dir2/added
Changes not staged for commit:
(use "git add <file>..." to update what will be committed)
(use "git restore <file>..." to discard changes in working directory)
-
modified: dir1/modified
Untracked files not listed (use -u option to show untracked files)
@@ -485,18 +470,15 @@ and have 1 and 2 different commits each, respectively.
Changes to be committed:
(use "git restore --staged <file>..." to unstage)
-
new file: dir2/added
Changes not staged for commit:
(use "git add <file>..." to update what will be committed)
(use "git restore <file>..." to discard changes in working directory)
-
modified: dir1/modified
Untracked files:
(use "git add <file>..." to include in what will be committed)
-
dir1/untracked
dir2/modified
dir2/untracked
@@ -543,18 +525,15 @@ and have 1 and 2 different commits each, respectively.
Changes to be committed:
(use "git restore --staged <file>..." to unstage)
-
new file: dir2/added
Changes not staged for commit:
(use "git add <file>..." to update what will be committed)
(use "git restore <file>..." to discard changes in working directory)
-
modified: dir1/modified
Untracked files:
(use "git add <file>..." to include in what will be committed)
-
dir1/untracked
dir2/modified
dir2/untracked
@@ -606,18 +585,15 @@ and have 1 and 2 different commits each, respectively.
Changes to be committed:
(use "git restore --staged <file>..." to unstage)
-
new file: ../dir2/added
Changes not staged for commit:
(use "git add <file>..." to update what will be committed)
(use "git restore <file>..." to discard changes in working directory)
-
modified: modified
Untracked files:
(use "git add <file>..." to include in what will be committed)
-
untracked
../dir2/modified
../dir2/untracked
@@ -677,18 +653,15 @@ and have 1 and 2 different commits each, respectively.
Changes to be committed:
(use "git restore --staged <file>..." to unstage)
-
<GREEN>new file: dir2/added<RESET>
Changes not staged for commit:
(use "git add <file>..." to update what will be committed)
(use "git restore <file>..." to discard changes in working directory)
-
<RED>modified: dir1/modified<RESET>
Untracked files:
(use "git add <file>..." to include in what will be committed)
-
<BLUE>dir1/untracked<RESET>
<BLUE>dir2/modified<RESET>
<BLUE>dir2/untracked<RESET>
@@ -803,18 +776,15 @@ and have 1 and 2 different commits each, respectively.
Changes to be committed:
(use "git restore --staged <file>..." to unstage)
-
new file: dir2/added
Changes not staged for commit:
(use "git add <file>..." to update what will be committed)
(use "git restore <file>..." to discard changes in working directory)
-
modified: dir1/modified
Untracked files:
(use "git add <file>..." to include in what will be committed)
-
dir1/untracked
dir2/modified
dir2/untracked
@@ -853,12 +823,10 @@ and have 1 and 2 different commits each, respectively.
Changes to be committed:
(use "git restore --staged <file>..." to unstage)
-
modified: dir1/modified
Untracked files:
(use "git add <file>..." to include in what will be committed)
-
dir1/untracked
dir2/
untracked
@@ -897,19 +865,16 @@ and have 1 and 2 different commits each, respectively.
Changes to be committed:
(use "git restore --staged <file>..." to unstage)
-
new file: dir2/added
new file: sm
Changes not staged for commit:
(use "git add <file>..." to update what will be committed)
(use "git restore <file>..." to discard changes in working directory)
-
modified: dir1/modified
Untracked files:
(use "git add <file>..." to include in what will be committed)
-
dir1/untracked
dir2/modified
dir2/untracked
@@ -957,14 +922,12 @@ and have 1 and 2 different commits each, respectively.
Changes to be committed:
(use "git restore --staged <file>..." to unstage)
-
new file: dir2/added
new file: sm
Changes not staged for commit:
(use "git add <file>..." to update what will be committed)
(use "git restore <file>..." to discard changes in working directory)
-
modified: dir1/modified
Submodule changes to be committed:
@@ -974,7 +937,6 @@ Submodule changes to be committed:
Untracked files:
(use "git add <file>..." to include in what will be committed)
-
dir1/untracked
dir2/modified
dir2/untracked
@@ -1020,12 +982,10 @@ and have 2 and 2 different commits each, respectively.
Changes not staged for commit:
(use "git add <file>..." to update what will be committed)
(use "git restore <file>..." to discard changes in working directory)
-
modified: dir1/modified
Untracked files:
(use "git add <file>..." to include in what will be committed)
-
dir1/untracked
dir2/modified
dir2/untracked
@@ -1069,14 +1029,12 @@ and have 2 and 2 different commits each, respectively.
Changes to be committed:
(use "git restore --source=HEAD^1 --staged <file>..." to unstage)
-
new file: dir2/added
new file: sm
Changes not staged for commit:
(use "git add <file>..." to update what will be committed)
(use "git restore <file>..." to discard changes in working directory)
-
modified: dir1/modified
Submodule changes to be committed:
@@ -1086,7 +1044,6 @@ Submodule changes to be committed:
Untracked files:
(use "git add <file>..." to include in what will be committed)
-
dir1/untracked
dir2/modified
dir2/untracked
@@ -1124,13 +1081,11 @@ and have 2 and 2 different commits each, respectively.
Changes to be committed:
(use "git restore --staged <file>..." to unstage)
-
modified: sm
Changes not staged for commit:
(use "git add <file>..." to update what will be committed)
(use "git restore <file>..." to discard changes in working directory)
-
modified: dir1/modified
Submodule changes to be committed:
@@ -1140,7 +1095,6 @@ Submodule changes to be committed:
Untracked files:
(use "git add <file>..." to include in what will be committed)
-
.gitmodules
dir1/untracked
dir2/modified
@@ -1236,14 +1190,12 @@ and have 2 and 2 different commits each, respectively.
Changes to be committed:
(use "git restore --staged <file>..." to unstage)
-
modified: sm
Changes not staged for commit:
(use "git add <file>..." to update what will be committed)
(use "git restore <file>..." to discard changes in working directory)
(commit or discard the untracked or modified content in submodules)
-
modified: dir1/modified
modified: sm (modified content)
@@ -1254,7 +1206,6 @@ Submodule changes to be committed:
Untracked files:
(use "git add <file>..." to include in what will be committed)
-
.gitmodules
dir1/untracked
dir2/modified
@@ -1296,13 +1247,11 @@ and have 2 and 2 different commits each, respectively.
Changes to be committed:
(use "git restore --staged <file>..." to unstage)
-
modified: sm
Changes not staged for commit:
(use "git add <file>..." to update what will be committed)
(use "git restore <file>..." to discard changes in working directory)
-
modified: dir1/modified
modified: sm (new commits)
@@ -1318,7 +1267,6 @@ Submodules changed but not updated:
Untracked files:
(use "git add <file>..." to include in what will be committed)
-
.gitmodules
dir1/untracked
dir2/modified
@@ -1380,13 +1328,11 @@ cat > expect << EOF
;
; Changes to be committed:
; (use "git restore --staged <file>..." to unstage)
-;
; modified: sm
;
; Changes not staged for commit:
; (use "git add <file>..." to update what will be committed)
; (use "git restore <file>..." to discard changes in working directory)
-;
; modified: dir1/modified
; modified: sm (new commits)
;
@@ -1402,7 +1348,6 @@ cat > expect << EOF
;
; Untracked files:
; (use "git add <file>..." to include in what will be committed)
-;
; .gitmodules
; dir1/untracked
; dir2/modified
@@ -1432,12 +1377,10 @@ and have 2 and 2 different commits each, respectively.
Changes not staged for commit:
(use "git add <file>..." to update what will be committed)
(use "git restore <file>..." to discard changes in working directory)
-
modified: dir1/modified
Untracked files:
(use "git add <file>..." to include in what will be committed)
-
.gitmodules
dir1/untracked
dir2/modified
@@ -1459,18 +1402,15 @@ and have 2 and 2 different commits each, respectively.
Changes to be committed:
(use "git restore --staged <file>..." to unstage)
-
modified: sm
Changes not staged for commit:
(use "git add <file>..." to update what will be committed)
(use "git restore <file>..." to discard changes in working directory)
-
modified: dir1/modified
Untracked files:
(use "git add <file>..." to include in what will be committed)
-
.gitmodules
dir1/untracked
dir2/modified
@@ -1582,13 +1522,11 @@ and have 2 and 2 different commits each, respectively.
Changes to be committed:
(use "git restore --staged <file>..." to unstage)
-
modified: sm
Changes not staged for commit:
(use "git add <file>..." to update what will be committed)
(use "git restore <file>..." to discard changes in working directory)
-
modified: dir1/modified
Untracked files not listed (use -u option to show untracked files)