#!/bin/bash -eu set -o pipefail readonly VERSION="${1:?}" cd "$(git rev-parse --show-toplevel)" cargo set-version "${VERSION//.b/-beta.}" cargo upgrade cargo update cargo check cargo test git add Cargo.{toml,lock} git commit -m "chore: version ${VERSION}" git tag -f -m "Version ${VERSION}" "${VERSION}"