chore: fix: don't fail release if commit/push is a no-op (for 7.yy.z releases) (#433)
* fix: fix set_tag_version_images.sh for bugfix releases Signed-off-by: Mykhailo Kuznietsov <mkuznets@redhat.com> * fix: fix set_tag_version_images.sh for bugfix releases Signed-off-by: Mykhailo Kuznietsov <mkuznets@redhat.com> * fixup! fix: fix set_tag_version_images.sh for bugfix releases --------- Signed-off-by: Mykhailo Kuznietsov <mkuznets@redhat.com>pull/435/head
parent
3b39854685
commit
3dd20f690a
|
|
@ -1,20 +0,0 @@
|
|||
#!/bin/bash
|
||||
# Copyright (c) 2017-2021 Red Hat, Inc.
|
||||
# All rights reserved. This program and the accompanying materials
|
||||
# are made available under the terms of the Eclipse Public License v1.0
|
||||
# which accompanies this distribution, and is available at
|
||||
# http://www.eclipse.org/legal/epl-v10.html
|
||||
|
||||
sed_in_place() {
|
||||
SHORT_UNAME=$(uname -s)
|
||||
if [ "$(uname)" == "Darwin" ]; then
|
||||
sed -i '' "$@"
|
||||
elif [ "${SHORT_UNAME:0:5}" == "Linux" ]; then
|
||||
sed -i "$@"
|
||||
fi
|
||||
}
|
||||
|
||||
# only use /latest plugins so updates are smoother (old plugins are deleted from registries with each new release)
|
||||
plugin_version="latest"
|
||||
sed_in_place -r -e "s#che.factory.default_editor=eclipse/che-theia/.*#che.factory.default_editor=eclipse/che-theia/$plugin_version#g" ../assembly/assembly-wsmaster-war/src/main/webapp/WEB-INF/classes/che/che.properties
|
||||
sed_in_place -r -e "s#che.workspace.devfile.default_editor=eclipse/che-theia/.*#che.workspace.devfile.default_editor=eclipse/che-theia/$plugin_version#g" ../assembly/assembly-wsmaster-war/src/main/webapp/WEB-INF/classes/che/che.properties
|
||||
|
|
@ -21,6 +21,15 @@ IMAGES_LIST=(
|
|||
quay.io/eclipse/che-server
|
||||
)
|
||||
|
||||
sed_in_place() {
|
||||
SHORT_UNAME=$(uname -s)
|
||||
if [ "$(uname)" == "Darwin" ]; then
|
||||
sed -i '' "$@"
|
||||
elif [ "${SHORT_UNAME:0:5}" == "Linux" ]; then
|
||||
sed -i "$@"
|
||||
fi
|
||||
}
|
||||
|
||||
loadMvnSettingsGpgKey() {
|
||||
set +x
|
||||
mkdir $HOME/.m2
|
||||
|
|
@ -395,13 +404,17 @@ bumpVersion() {
|
|||
}
|
||||
|
||||
updateImageTagsInCheServer() {
|
||||
cd che-server
|
||||
git checkout ${BRANCH}
|
||||
cd .ci
|
||||
./set_tag_version_images.sh ${CHE_VERSION}
|
||||
cd ..
|
||||
git commit -asm "chore: Set ${CHE_VERSION} release image tags"
|
||||
git push origin ${BRANCH}
|
||||
pushd che-server >/dev/null
|
||||
git checkout ${BRANCH}
|
||||
plugin_version="latest"
|
||||
sed_in_place -r -e "s#che.factory.default_editor=eclipse/che-theia/.*#che.factory.default_editor=eclipse/che-theia/$plugin_version#g" assembly/assembly-wsmaster-war/src/main/webapp/WEB-INF/classes/che/che.properties
|
||||
sed_in_place -r -e "s#che.workspace.devfile.default_editor=eclipse/che-theia/.*#che.workspace.devfile.default_editor=eclipse/che-theia/$plugin_version#g" assembly/assembly-wsmaster-war/src/main/webapp/WEB-INF/classes/che/che.properties
|
||||
|
||||
if [[ $(git diff --stat) != '' ]]; then
|
||||
git commit -asm "chore: Set ${CHE_VERSION} release image tags"
|
||||
git push origin ${BRANCH}
|
||||
fi
|
||||
popd >/dev/null
|
||||
}
|
||||
|
||||
installMaven
|
||||
|
|
|
|||
Loading…
Reference in New Issue