More sanity checks

This commit is contained in:
Alexandre Aubin 2023-02-13 20:55:33 +01:00
parent 03cdffca88
commit d95027ef22

View file

@ -259,12 +259,20 @@ function fetch_package_to_test() {
fi fi
fi fi
fi fi
else ! git ls-remote --quiet --exit-code $path_to_package_to_test ${gitbranch##-b } >/dev/null
log_critical "Branch ${gitbranch##-b } doesn't exists (anymore?) ?"
fi
log_info " on branch ${gitbranch##-b }" log_info " on branch ${gitbranch##-b }"
# Clone the repository # Clone the repository
git clone --quiet $path_to_package_to_test $gitbranch "$package_path" git clone --quiet $path_to_package_to_test $gitbranch "$package_path"
if [[ ! -e "$package_path" ]]
then
log_critical "Failed to git clone the repo / branch ?"
fi
log_info " (commit $(git -C $package_path rev-parse HEAD))" log_info " (commit $(git -C $package_path rev-parse HEAD))"
# If it's a local directory # If it's a local directory