-
Notifications
You must be signed in to change notification settings - Fork 621
Expand file tree
/
Copy pathrelease.sh
More file actions
executable file
·18 lines (14 loc) · 912 Bytes
/
release.sh
File metadata and controls
executable file
·18 lines (14 loc) · 912 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#!/bin/sh
echo $1
RELEASE_VERSION=$1
if [ -z "$RELEASE_VERSION" ]; then
echo "Usage: $0 <release-version>"
exit 1
fi
echo "Release version: $RELEASE_VERSION"
# update version in main pom.xml
sed -i "s|<clickhouse-java.version>.*<\/clickhouse-java.version>|<clickhouse-java.version>${RELEASE_VERSION}<\/clickhouse-java.version>|g" pom.xml
# udpate examples with new version
find ./examples/ -type f -name "pom.xml" -exec sed -i "s|<clickhouse-java.version>.*<\/clickhouse-java.version>|<clickhouse-java.version>${RELEASE_VERSION}-SNAPSHOT<\/clickhouse-java.version>|g" '{}' \;
find ./examples/ -type f -name "gradle.properties" -exec sed -i "s|^ch_java_client_version=.*$|ch_java_client_version=${RELEASE_VERSION}|g" '{}' \;
find ./performance/ -type f -name "pom.xml" -exec sed -i "s|<ch.jdbc.revision>.*<\/ch.jdbc.revision>|<ch.jdbc.revision>${RELEASE_VERSION}-SNAPSHOT<\/ch.jdbc.revision>|g" '{}' \;