Skip to content

Commit

Permalink
Adjust some CI/CD things
Browse files Browse the repository at this point in the history
Emits .gma without a version postfix
Writes version to the changelog
  • Loading branch information
NotMyWing committed Dec 7, 2020
1 parent cab7fe6 commit d2cde69
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
14 changes: 7 additions & 7 deletions .travis.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,24 +4,24 @@ REGEX_SLUG="(.+)/(.+)"
[[ $TRAVIS_REPO_SLUG =~ $REGEX_SLUG ]]
REPO_NAME=${BASH_REMATCH[2]}

releaseName=""
zipName=""
gmaName=""

if [ ! -z "$TRAVIS_TAG" ]
then
export TAGGED_RELEASE=true

releaseName="${REPO_NAME}-${TRAVIS_TAG}"
zipName="${REPO_NAME}-${TRAVIS_TAG}"
gmaName="${REPO_NAME}"
else
export TAGGED_RELEASE=false
fi

export DEST_ARCHIVE="$(echo ${releaseName} | tr '[:upper:]' '[:lower:]')"
export DEST_ARCHIVE="$(echo ${zipName} | tr '[:upper:]' '[:lower:]')"
export DEST_GMA="$(echo ${gmaName} | tr '[:upper:]' '[:lower:]')"

gulp build
gulp travisPostBuild

mv ./dest/gamemode.zip ./dest/$DEST_ARCHIVE.zip
./gmad create -folder dest -out dest/$DEST_ARCHIVE.gma

echo "Release = ${releaseName}"
echo "Tagged release = ${TAGGED_RELEASE}"
./gmad create -folder dest -out dest/$DEST_GMA.gma
4 changes: 2 additions & 2 deletions tools/travisPostBuild.js
Original file line number Diff line number Diff line change
Expand Up @@ -56,9 +56,9 @@ function generateChangeLog(cb) {
}

if (changelog) {
changelog = `Changes since ${tag}:\n${changelog}`
changelog = `# Version ${tag}\nChanges since ${tag}:\n${changelog}`
} else {
changelog = `There have been no changes since ${tag}`
changelog = `# Version ${tag}\nThere have been no changes since ${tag}.`
}

writeFileSync('dest/changelog.md', changelog);
Expand Down

0 comments on commit d2cde69

Please sign in to comment.