mirror of
https://github.com/saltstack/salt-bootstrap.git
synced 2025-04-16 09:40:21 +00:00
Fix git invocation fail when man
command is not available
This commit is contained in:
parent
009d7c7728
commit
79789642a9
1 changed files with 1 additions and 1 deletions
|
@ -1291,7 +1291,7 @@ __git_clone_and_checkout() {
|
|||
# Let's try shallow cloning to speed up.
|
||||
# Test for "--single-branch" option introduced in git 1.7.10, the minimal version of git where the shallow
|
||||
# cloning we need actually works
|
||||
if [ "$(git clone --help | grep 'single-branch')" != "" ]; then
|
||||
if [ "$(git clone 2>&1 | grep 'single-branch')" != "" ]; then
|
||||
# The "--single-branch" option is supported, attempt shallow cloning
|
||||
echoinfo "Attempting to shallow clone $GIT_REV from Salt's repository ${_SALT_REPO_URL}"
|
||||
git clone --depth 1 --branch "$GIT_REV" "$_SALT_REPO_URL" "$__SALT_CHECKOUT_REPONAME"
|
||||
|
|
Loading…
Add table
Reference in a new issue