mirror of
https://github.com/git/git.git
synced 2026-08-03 06:31:08 +00:00
Add argument 'no' commit/status option -u|--untracked-files
This new argument teaches Git to not look for any untracked files, saving cycles on slow file systems, or large repos. Signed-off-by: Marius Storm-Olsen <marius@trolltech.com>
This commit is contained in:
committed by
Junio C Hamano
parent
4bfee30a98
commit
6c2ce048bb
@@ -67,6 +67,28 @@ test_expect_success 'status (2)' '
|
||||
|
||||
'
|
||||
|
||||
cat >expect <<EOF
|
||||
# On branch master
|
||||
# Changes to be committed:
|
||||
# (use "git reset HEAD <file>..." to unstage)
|
||||
#
|
||||
# new file: dir2/added
|
||||
#
|
||||
# Changed but not updated:
|
||||
# (use "git add <file>..." to update what will be committed)
|
||||
#
|
||||
# modified: dir1/modified
|
||||
#
|
||||
# Untracked files not listed (use -u option to show untracked files)
|
||||
EOF
|
||||
test_expect_success 'status -uno' '
|
||||
mkdir dir3 &&
|
||||
: > dir3/untracked1 &&
|
||||
: > dir3/untracked2 &&
|
||||
git status -uno >output &&
|
||||
test_cmp expect output
|
||||
'
|
||||
|
||||
cat >expect <<EOF
|
||||
# On branch master
|
||||
# Changes to be committed:
|
||||
@@ -91,9 +113,6 @@ cat >expect <<EOF
|
||||
# untracked
|
||||
EOF
|
||||
test_expect_success 'status -unormal' '
|
||||
mkdir dir3 &&
|
||||
: > dir3/untracked1 &&
|
||||
: > dir3/untracked2 &&
|
||||
git status -unormal >output &&
|
||||
test_cmp expect output
|
||||
'
|
||||
|
||||
Reference in New Issue
Block a user