aboutsummaryrefslogtreecommitdiffstats
path: root/contrib/version-bump
diff options
context:
space:
mode:
authorMatt Strapp <matt@mattstrapp.net>2024-10-29 16:49:41 -0500
committerMatt Strapp <matt@mattstrapp.net>2024-10-29 16:49:41 -0500
commita989ea718341075f841752d8cd65c0f0eabd9c6a (patch)
tree7017c102ad7df28dd5f3ce9f6d4bd7b5fbfa2e1d /contrib/version-bump
parentonly run in working directory :) (diff)
downloadlocusts-a989ea718341075f841752d8cd65c0f0eabd9c6a.tar
locusts-a989ea718341075f841752d8cd65c0f0eabd9c6a.tar.gz
locusts-a989ea718341075f841752d8cd65c0f0eabd9c6a.tar.bz2
locusts-a989ea718341075f841752d8cd65c0f0eabd9c6a.tar.lz
locusts-a989ea718341075f841752d8cd65c0f0eabd9c6a.tar.xz
locusts-a989ea718341075f841752d8cd65c0f0eabd9c6a.tar.zst
locusts-a989ea718341075f841752d8cd65c0f0eabd9c6a.zip
Update changesets.yml and version-bump script
- Update changesets.yml to install additional software packages - Modify version-bump script to pull the GIT_TAG from changeset if not set - Bump version in multiple files and remove snapshot from gradle.properties Signed-off-by: Matt Strapp <matt@mattstrapp.net>
Diffstat (limited to 'contrib/version-bump')
-rw-r--r--contrib/version-bump11
1 files changed, 8 insertions, 3 deletions
diff --git a/contrib/version-bump b/contrib/version-bump
index fff89c2..09ca6a9 100644
--- a/contrib/version-bump
+++ b/contrib/version-bump
@@ -1,12 +1,11 @@
#!/usr/bin/env bash
if [ -z "$GIT_TAG" ]; then
- echo "GIT_TAG is not set, guessing from changeset"
+ echo "GIT_TAG is not set, pulling from changeset"
GIT_TAG=$(jq -r '.version' src/packages/locusts/package.json)
fi
OLD_TAG=$(jq -r '.version' package.json)
-
echo "Bumping version from $OLD_TAG to $GIT_TAG"
rg "$OLD_TAG" --files-with-matches --iglob \!\*lock\* --iglob \!go.mod --iglob \!deno.json --iglob \!package.json --iglob \!\*.md "$(pwd)" | xargs sed -i "s/$OLD_TAG/$GIT_TAG/g"
@@ -15,4 +14,10 @@ rg "$OLD_TAG" --files-with-matches --iglob \!\*lock\* --iglob \!go.mod --iglob \
AUTOTOOLS_TAG=${GIT_TAG//\./:}
OLD_TAG=${OLD_TAG//\./:}
-sed -i "s/$GIT_TAG/$AUTOTOOLS_TAG/g" GNUmakefile.am \ No newline at end of file
+sed -i "s/$GIT_TAG/$AUTOTOOLS_TAG/g" GNUmakefile.am
+
+# remove the snapshot from gradle
+sed -i "s/-SNAPSHOT//g" gradle.properties
+
+# bump the main package.json too
+jq ".version = \"$GIT_TAG\"" package.json | sponge package.json \ No newline at end of file