From 19fcec84d8d7d21e796c7624e521b60d28ee21ed Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sun, 7 Apr 2024 20:45:59 +0200 Subject: Adding upstream version 16.2.11+ds. Signed-off-by: Daniel Baumann --- src/jaegertracing/thrift/lib/rs/release.sh | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100755 src/jaegertracing/thrift/lib/rs/release.sh (limited to 'src/jaegertracing/thrift/lib/rs/release.sh') diff --git a/src/jaegertracing/thrift/lib/rs/release.sh b/src/jaegertracing/thrift/lib/rs/release.sh new file mode 100755 index 000000000..c4e5b4892 --- /dev/null +++ b/src/jaegertracing/thrift/lib/rs/release.sh @@ -0,0 +1,26 @@ +#!/bin/bash + +set -o errexit +set -o pipefail +set -o nounset + +if ! [[ $# -eq 1 && $1 =~ ^[0-9](\.[0-9][0-9]*){2}$ ]]; then + (>&2 echo "Usage: ./publish-crate.sh [THRIFT_RELEASE_VERSION] ") + (>&2 echo " THRIFT_RELEASE_VERSION is in semantic versioning format, i.e. #.##.##") + exit 1 +fi + +THRIFT_RELEASE_VERSION=${1:-} + +echo "Updating Cargo.toml to ${THRIFT_RELEASE_VERSION}" +sed -i.old -e "s/^version = .*$/version = \"${THRIFT_RELEASE_VERSION}\"/g" Cargo.toml +rm Cargo.toml.old + +echo "Committing updated Cargo.toml" +git add Cargo.toml +git commit -m "Update thrift crate version to ${THRIFT_RELEASE_VERSION}" -m "Client: rs" + +echo "Packaging and releasing rust thrift crate with version ${THRIFT_RELEASE_VERSION}" +cargo clean +cargo package +cargo publish -- cgit v1.2.3