diff options
author | jak1 <mike.wollmann@gmail.com> | 2021-03-16 17:26:14 +0100 |
---|---|---|
committer | jak1 <mike.wollmann@gmail.com> | 2021-03-16 17:26:14 +0100 |
commit | 9b6a1bb23cafdec63f40bfe2cf219c1799c80677 (patch) | |
tree | 6d9c4c0b6e863d6eea60210a5ba3267bcaa2c15d /manaplus.sh | |
parent | d91b7c0b87e2ac10039b304df2198ced636a43ce (diff) | |
download | docker-windows-builder-9b6a1bb23cafdec63f40bfe2cf219c1799c80677.tar.gz docker-windows-builder-9b6a1bb23cafdec63f40bfe2cf219c1799c80677.tar.bz2 docker-windows-builder-9b6a1bb23cafdec63f40bfe2cf219c1799c80677.tar.xz docker-windows-builder-9b6a1bb23cafdec63f40bfe2cf219c1799c80677.zip |
CI test using CI variables
Diffstat (limited to 'manaplus.sh')
-rw-r--r-- | manaplus.sh | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/manaplus.sh b/manaplus.sh index 215340b..0bc7d9f 100644 --- a/manaplus.sh +++ b/manaplus.sh @@ -16,6 +16,10 @@ dll_check(){ # CI_COMMIT_TAG="v2.1.1.1" # <- test version # CI_COMMIT_TAG="s20210101" # <- test snapshot2 get_version_by_tag(){ + latest_tag=`git -c 'versionsort.suffix=-' \ + ls-remote --exit-code --refs --sort='version:refname' --tags ${MP_REPOSITORY} '*.*.*' \ + | tail --lines=1 \ + | cut --delimiter='/' --fields=3` IFS='.' read -r -a array <<< "$CI_COMMIT_TAG" # splits commit tag in array [ "${CI_COMMIT_TAG:0:1}" == "v" ] \ && V="${array[0]:1}.${array[1]}.${array[2]}.${array[3]}" # add dots to version @@ -23,6 +27,7 @@ get_version_by_tag(){ && V="snapshot-${CI_COMMIT_TAG:1}" # just replace 's' with 'snapshot-' [ "${CI_COMMIT_TAG}" == "" ] \ && echo "!WARN: no tag set, using test-0.0.0.1!" \ + && echo "latest tag: '${latest_tag}' on '${MP_REPOSITORY}' master" \ && V="test-0.0.0.1" # test versions, (not running from tags) export PRODUCT_VERSION=$V export VERSION=$V @@ -77,8 +82,9 @@ make_portable $dll_dir #./packwin || exit 1 # disabled (not required @mana-launcher) # artifacts -#cp /manaplus/packaging/windows/manaplus-*.exe /builds/jak89_1/docker-testing/build/ || exit 1 -cp /tmp/*.zip /builds/jak89_1/docker-testing/build/ || exit 1 # copy portable client zip file -# TODO: checksum [zip->sha->{version?}.sha] /builds/jak89_1/docker-testing/build/ -cp /manaplus/build/tmp/config.log /builds/jak89_1/docker-testing/logs/ || true -cp /manaplus/build/make2.log /builds/jak89_1/docker-testing/logs/ || true +#cp /manaplus/packaging/windows/manaplus-*.exe ${CI_PROJECT_DIR}/build/ || exit 1 +cp /tmp/*.zip ${CI_PROJECT_DIR}/build/ || exit 1 # copy portable client zip file +# TODO: checksum [zip->sha->{version?}.sha] ${CI_PROJECT_DIR}/build/ +cp /manaplus/build/tmp/config.log ${CI_PROJECT_DIR}/logs/ || true +cp /manaplus/build/make2.log ${CI_PROJECT_DIR}/logs/ || true + |