Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tasks/workunit.py: when cloning, use --depth=1 #14214

Merged
merged 1 commit into from Mar 29, 2017
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 2 additions & 0 deletions qa/tasks/workunit.py
Expand Up @@ -321,6 +321,7 @@ def _run_tests(ctx, refspec, role, tests, env, subdir=None, timeout=None):
run.Raw('&&'),
'git',
'clone',
'--depth=1',
Copy link
Contributor

@tchaikov tchaikov Mar 29, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we can also pass --no-checkout to git clone, to save some time to check out the HEAD. we will run git checkout later on anyway.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we could, but the time is totally dominated by the remote pack creation and transmission. I can't observe any difference at all from --no-checkout.

git_url,
clonedir,
run.Raw('&&'),
Expand Down Expand Up @@ -348,6 +349,7 @@ def _run_tests(ctx, refspec, role, tests, env, subdir=None, timeout=None):
run.Raw('&&'),
'git',
'clone',
'--depth=1',
alt_git_url,
clonedir,
run.Raw('&&'),
Expand Down