Commit 7d8b9f2d authored by OAI Jenkins's avatar OAI Jenkins
Browse files

CI: do perfect merge even in case of shallow workspace

Signed-off-by: default avatarOAI Jenkins <>
parent cca5bcd9
......@@ -103,6 +103,17 @@ esac
# If the repo workspace is shallow, unshallow it
NB_COMMITS=`git log --oneline | wc -l`
if [ $NB_COMMITS -eq 1 ]
git config remote.origin.fetch "+refs/heads/*:refs/remotes/origin/*" > /dev/null 2>&1
echo "git remote update"
git remote update > /dev/null 2>&1
echo "git fetch --prune --unshallow"
git fetch --prune --unshallow > /dev/null 2>&1
if [[ $TARGET_COMMIT_ID == "latest" ]]
TARGET_COMMIT_ID=`git log -n1 --pretty=format:%H origin/$TARGET_BRANCH`
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment