Skip to content

Commit

Permalink
fix(release.sh): lint and test before releasing
Browse files Browse the repository at this point in the history
  • Loading branch information
stackmystack committed Sep 6, 2024
1 parent a0832d8 commit bc5aa6c
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion scripts/release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ set -e
version=${1:-$(git cliff --bumped-version)}

echo "Preparing $version..."
# lint and test first
just lint
just test --retries 3
# update the version
msg="# managed by release.sh"
sed -E -i "s/^version = .*\s+$msg$/version = \"${version#v}\" $msg/" Cargo.toml
Expand All @@ -24,4 +27,4 @@ changelog=$(git cliff --unreleased --strip all)
# create a tag
git tag -a "$version" -m "Release $version" -m "$changelog"
echo "Done!"
echo "Now push the commit (git push) and the tag (git push --tags)."
echo "Now push the commit (git push origin master) and the tag (git push origin refs/tags/$version)."

0 comments on commit bc5aa6c

Please sign in to comment.