File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -259,7 +259,7 @@ sub list_modified {
259259 @tracked = map {
260260 chomp $_ ;
261261 unquote_path($_ );
262- } run_cmd_pipe(qw( git ls-files --exclude-standard -- ) , @ARGV );
262+ } run_cmd_pipe(qw( git ls-files --) , @ARGV );
263263 return if (!@tracked );
264264 }
265265
Original file line number Diff line number Diff line change @@ -138,6 +138,20 @@ test_expect_success 'real edit works' '
138138 test_cmp expected output
139139'
140140
141+ test_expect_success ' skip files similarly as commit -a' '
142+ git reset &&
143+ echo file >.gitignore &&
144+ echo changed >file &&
145+ echo y | git add -p file &&
146+ git diff >output &&
147+ git reset &&
148+ git commit -am commit &&
149+ git diff >expected &&
150+ test_cmp expected output &&
151+ git reset --hard HEAD^
152+ '
153+ rm -f .gitignore
154+
141155if test " $( git config --bool core.filemode) " = false
142156then
143157 say ' skipping filemode tests (filesystem does not properly support modes)'
You can’t perform that action at this time.
0 commit comments