From 9ac1d33f1e90c6c10f07f13f6caec625cf30ab92 Mon Sep 17 00:00:00 2001 From: OpenSauce04 Date: Mon, 27 May 2024 00:28:14 +0100 Subject: [PATCH] Release source archive names now use version number instead of git info --- .ci/source.sh | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/.ci/source.sh b/.ci/source.sh index d07c222b8..ca2c6c723 100755 --- a/.ci/source.sh +++ b/.ci/source.sh @@ -2,7 +2,13 @@ GITDATE="`git show -s --date=short --format='%ad' | sed 's/-//g'`" GITREV="`git show -s --format='%h'`" -REV_NAME="lime3ds-unified-source-${GITDATE}-${GITREV}" + +# Determine the name of the release being built. +if [[ "$GITHUB_REF_TYPE" == "tag" ]]; then + RELEASE_NAME=lime3ds-unified-source-$GITHUB_REF_NAME +else + RELEASE_NAME=lime3ds-unified-source-head +fi COMPAT_LIST='dist/compatibility_list/compatibility_list.json' @@ -13,9 +19,9 @@ touch "${COMPAT_LIST}" #wget -q https://api.citra-emu.org/gamedb -O "${COMPAT_LIST}" git describe --abbrev=0 --always HEAD > GIT-COMMIT git describe --tags HEAD > GIT-TAG || echo 'unknown' > GIT-TAG -git archive-all --include "${COMPAT_LIST}" --include GIT-COMMIT --include GIT-TAG --force-submodules artifacts/"${REV_NAME}.tar" +git archive-all --include "${COMPAT_LIST}" --include GIT-COMMIT --include GIT-TAG --force-submodules artifacts/"${RELEASE_NAME}.tar" cd artifacts/ -xz -T0 -9 "${REV_NAME}.tar" -sha256sum "${REV_NAME}.tar.xz" > "${REV_NAME}.tar.xz.sha256sum" +xz -T0 -9 "${RELEASE_NAME}.tar" +sha256sum "${RELEASE_NAME}.tar.xz" > "${RELEASE_NAME}.tar.xz.sha256sum" cd ..