diff options
author | Matt Strapp <matt@mattstrapp.net> | 2024-10-29 16:14:09 -0500 |
---|---|---|
committer | Matt Strapp <matt@mattstrapp.net> | 2024-10-29 16:14:09 -0500 |
commit | 052e5e490b6b80baac6fb8f81aed70aa934d3567 (patch) | |
tree | 3d2de2445ec085054c5e1cef493f251708562086 | |
parent | version de-bump everything (diff) | |
download | locusts-052e5e490b6b80baac6fb8f81aed70aa934d3567.tar locusts-052e5e490b6b80baac6fb8f81aed70aa934d3567.tar.gz locusts-052e5e490b6b80baac6fb8f81aed70aa934d3567.tar.bz2 locusts-052e5e490b6b80baac6fb8f81aed70aa934d3567.tar.lz locusts-052e5e490b6b80baac6fb8f81aed70aa934d3567.tar.xz locusts-052e5e490b6b80baac6fb8f81aed70aa934d3567.tar.zst locusts-052e5e490b6b80baac6fb8f81aed70aa934d3567.zip |
Add verion bumping script
Signed-off-by: Matt Strapp <matt@mattstrapp.net>
-rw-r--r-- | .github/workflows/changesets.yml | 2 | ||||
-rw-r--r-- | contrib/version-bump | 19 | ||||
-rw-r--r-- | docs/BEAM.md | 2 | ||||
-rw-r--r-- | package.json | 2 |
4 files changed, 23 insertions, 2 deletions
diff --git a/.github/workflows/changesets.yml b/.github/workflows/changesets.yml index e5613b8..b0cf024 100644 --- a/.github/workflows/changesets.yml +++ b/.github/workflows/changesets.yml @@ -19,6 +19,8 @@ jobs: key: ${{ runner.os }}-turbo-${{ github.sha }} restore-keys: | ${{ runner.os }}-turbo- + - name: Install ripgrep + run: sudo apt-get -y install ripgrep - name: Install pnpm and dependencies uses: pnpm/action-setup@v4 with: diff --git a/contrib/version-bump b/contrib/version-bump new file mode 100644 index 0000000..925fa17 --- /dev/null +++ b/contrib/version-bump @@ -0,0 +1,19 @@ +#!/usr/bin/env bash + +if [ -z "$GIT_TAG" ]; then + echo "GIT_TAG is not set" + exit 1 +fi + +OLD_TAG=$(jq -r '.version' package.json) + +rg "$OLD_TAG" --files-with-matches --iglob \!\*lock\* --iglob \!go.mod --iglob \!deno.json --iglob \!package.json | xargs sed -i "s/$OLD_TAG/$GIT_TAG/g" + +# fiddlge with autotools + +AUTOTOOLS_TAG=$(echo $GIT_TAG | sed 's/\./:/g') +OLD_TAG=$(echo $OLD_TAG | sed 's/\./:/g') + +echo $GIT_TAG + +sed -i "s/$GIT_TAG/$AUTOTOOLS_TAG/g" GNUmakefile.am
\ No newline at end of file diff --git a/docs/BEAM.md b/docs/BEAM.md index 5e547cb..3187b23 100644 --- a/docs/BEAM.md +++ b/docs/BEAM.md @@ -15,7 +15,7 @@ by adding `locusts` to your list of dependencies in `mix.exs`: ```elixir def deps do [ - {:locusts, "~> 0.0.0"} + {:locusts, ">= 0.0.0"} ] end ``` diff --git a/package.json b/package.json index acdedf5..1c531f8 100644 --- a/package.json +++ b/package.json @@ -19,6 +19,6 @@ "format": "prettier --write \"**/*.{ts,tsx,md}\"", "lint": "turbo lint", "test": "turbo test", - "publish-packages": "turbo build && changeset publish" + "publish-packages": "bash ./contrib/version-bump && turbo build && changeset publish" } } |