mirror of
https://git.icinga.com/packaging/rpm-icingaweb2.git
synced 2025-07-30 17:34:13 +02:00
icinga2/icingaweb2: Update get_snapshot to support branch/url changes
This commit is contained in:
parent
8be508efe7
commit
909c1f2e55
@ -37,7 +37,11 @@ if [ -d "${PROJECT}.git/" ]; then
|
||||
echo "This is not a GIT repository: $(pwd)" >&2
|
||||
exit 1
|
||||
fi
|
||||
if [ "$(git config remote.origin.url)" != "${UPSTREAM_GIT_URL}" ]; then
|
||||
git remote set-url origin "${UPSTREAM_GIT_URL}"
|
||||
fi
|
||||
git fetch origin -p
|
||||
git checkout -f "${UPSTREAM_GIT_BRANCH}"
|
||||
git reset --hard "origin/${UPSTREAM_GIT_BRANCH}"
|
||||
git clean -fdx
|
||||
else
|
||||
|
Loading…
x
Reference in New Issue
Block a user