Skip to content

Commit

Permalink
Update looker-snapshot.sh
Browse files Browse the repository at this point in the history
  • Loading branch information
wnob committed Feb 14, 2024
1 parent 9728cc5 commit f8de01e
Showing 1 changed file with 12 additions and 12 deletions.
24 changes: 12 additions & 12 deletions looker-snapshot.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,27 +16,27 @@
# limitations under the License.
#

# $1 is the artifact ID
# $2 is the version
# $3 is the JAR path
# $1 is the sub-project directory
# $2 is the artifact ID
# $3 is the version
function snapshot_upload {
mvn deploy:deploy-file \
-DgroupId=org.apache.calcite.avatica \
-DartifactId="$1" \
-Dversion="$2" \
-DartifactId="$2" \
-Dversion="$3" \
-Dpackaging=jar \
-Dfile="$3" \
-DgeneratePom=true \
-Dfile="./$1/build/libs/$2-$3.jar" \
-DgeneratePom=false \
-DpomFile="./$1/build/publications/$1/pom-default.xml" \
-DrepositoryId=nexus \
-Durl=https://nexusrepo.looker.com/repository/maven-snapshots/
}

./gradlew build && ./gradlew jar && ./gradlew generatePom && (
./gradlew build -x test && ./gradlew jar && ./gradlew generatePom && (
VERSION="$(sed -n 's/^calcite\.avatica\.version=\([^ ]*\).*/\1/p' gradle.properties)-SNAPSHOT"
snapshot_upload avatica-core "$VERSION" "./core/build/libs/avatica-core-$VERSION.jar"
snapshot_upload avatica-server "$VERSION" "./server/build/libs/avatica-server-$VERSION.jar"
snapshot_upload avatica-metrics "$VERSION" "./metrics/build/libs/avatica-metrics-$VERSION.jar"
snapshot_upload avatica "$VERSION" "./shaded/core/build/libs/avatica-$VERSION-shadow.jar"
snapshot_upload core avatica-core "$VERSION"
snapshot_upload server avatica-server "$VERSION"
snapshot_upload metrics avatica-metrics "$VERSION"
echo
echo "Done uploading version ${VERSION} to Looker Nexus Snapshots!"
)

0 comments on commit f8de01e

Please sign in to comment.