Default clone_repo to master if branch not found
Behavior change from set -e causes attempt to checkout an invalid branch to fail. Explicitly fall back to master if the requested branch name checkout fails. Change-Id: Ib20a4910275126fc3949b06dbc91a301c2d04406
This commit is contained in:
parent
98e85fb012
commit
d43b8ccede
@ -169,6 +169,6 @@ else
|
|||||||
# directory already existed we might have checked out something else
|
# directory already existed we might have checked out something else
|
||||||
# before so just do it again).
|
# before so just do it again).
|
||||||
(cd $local_dir &&
|
(cd $local_dir &&
|
||||||
git checkout $BRANCH &&
|
(git checkout $BRANCH || git checkout master) &&
|
||||||
git pull --ff-only)
|
git pull --ff-only)
|
||||||
fi
|
fi
|
||||||
|
Loading…
Reference in New Issue
Block a user