Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions builtin/clone.c
Original file line number Diff line number Diff line change
Expand Up @@ -957,6 +957,9 @@ int cmd_clone(int argc, const char **argv, const char *prefix)

struct argv_array ref_prefixes = ARGV_ARRAY_INIT;

if (!isatty(2))
option_verbosity = -1;

packet_trace_identity("clone");
argc = parse_options(argc, argv, prefix, builtin_clone_options,
builtin_clone_usage, 0);
Expand Down
2 changes: 1 addition & 1 deletion t/t5550-http-fetch-dumb.sh
Original file line number Diff line number Diff line change
Expand Up @@ -332,7 +332,7 @@ test_expect_success 'redirects can be forbidden/allowed' '
test_must_fail git -c http.followRedirects=false \
clone $HTTPD_URL/dumb-redir/repo.git dumb-redir &&
git -c http.followRedirects=true \
clone $HTTPD_URL/dumb-redir/repo.git dumb-redir 2>stderr
clone --verbose $HTTPD_URL/dumb-redir/repo.git dumb-redir 2>stderr
'

test_expect_success 'redirects are reported to stderr' '
Expand Down
7 changes: 6 additions & 1 deletion t/t5601-clone.sh
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ test_expect_success 'clone with excess parameters (2)' '

test_expect_success C_LOCALE_OUTPUT 'output from clone' '
rm -fr dst &&
git clone -n "file://$(pwd)/src" dst >output 2>&1 &&
git clone --verbose -n "file://$(pwd)/src" dst >output 2>&1 &&
test $(grep Clon output | wc -l) = 1
'

Expand Down Expand Up @@ -297,6 +297,11 @@ test_expect_success 'clone from original with relative alternate' '
grep /src/\\.git/objects target-10/objects/info/alternates
'

test_expect_success 'clone quietly without terminal' '
GIT_PROGRESS_DELAY=0 git clone src progress 2>err &&
test_must_be_empty err
'

test_expect_success 'clone checking out a tag' '
git clone --branch=some-tag src dst.tag &&
GIT_DIR=src/.git git rev-parse some-tag >expected &&
Expand Down
8 changes: 0 additions & 8 deletions t/t7406-submodule-update.sh
Original file line number Diff line number Diff line change
Expand Up @@ -115,18 +115,10 @@ Submodule path '../super/submodule': checked out '$submodulesha1'
EOF

cat <<EOF >expect2
Cloning into '$pwd/recursivesuper/super/merging'...
Cloning into '$pwd/recursivesuper/super/none'...
Cloning into '$pwd/recursivesuper/super/rebasing'...
Cloning into '$pwd/recursivesuper/super/submodule'...
Submodule 'merging' ($pwd/merging) registered for path '../super/merging'
Submodule 'none' ($pwd/none) registered for path '../super/none'
Submodule 'rebasing' ($pwd/rebasing) registered for path '../super/rebasing'
Submodule 'submodule' ($pwd/submodule) registered for path '../super/submodule'
done.
done.
done.
done.
EOF

test_expect_success 'submodule update --init --recursive from subdirectory' '
Expand Down