Skip to content

Commit

Permalink
Release workflow (#5)
Browse files Browse the repository at this point in the history
Merged without review.
  • Loading branch information
ryannedolan authored May 9, 2023
1 parent 668ea34 commit 12ffab6
Show file tree
Hide file tree
Showing 4 changed files with 63 additions and 0 deletions.
20 changes: 20 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
name: Publish release packages
on:
release:
types: [created]
jobs:
publish:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up Java
uses: actions/setup-java@v3
with:
java-version: '11'
distribution: 'adopt'
- name: Validate Gradle wrapper
uses: gradle/wrapper-validation-action@ccb4328a959376b642e027874838f60f8e596de3
- name: Publish package
uses: gradle/gradle-build-action@749f47bda3e44aa060e82d7b3ef7e40d953bd629
with:
arguments: publish
3 changes: 3 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -35,4 +35,7 @@ undeploy:
deploy-samples:
kubectl apply -f ./deploy/samples

release:
./gradlew publish

.PHONY: build clean quickstart deploy-dev-environment deploy deploy-samples integration-tests
20 changes: 20 additions & 0 deletions hoptimator-catalog/build.gradle
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
plugins {
id 'java-library'
id 'idea'
id 'maven-publish'
}

dependencies {
Expand All @@ -11,6 +12,25 @@ dependencies {
testImplementation libs.assertj
}

publishing {
repositories {
maven {
url = "https://maven.pkg.github.com/linkedin/Hoptimator"
credentials {
username = System.getenv('GITHUB_ACTOR')
password = System.getenv('GITHUB_TOKEN')
}
}
}
publications {
maven(MavenPublication) {
groupId = 'com.linkedin.hoptimator'
artifactId = 'hoptimator-catalog'
from components.java
}
}
}

tasks.withType(JavaCompile) {
options.compilerArgs << '-Xlint:deprecation'
options.compilerArgs << '-Xlint:unchecked'
Expand Down
20 changes: 20 additions & 0 deletions hoptimator-planner/build.gradle
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
plugins {
id 'java-library'
id 'idea'
id 'maven-publish'
}

dependencies {
Expand All @@ -10,6 +11,25 @@ dependencies {
api libs.calciteCore
}

publishing {
repositories {
maven {
url = "https://maven.pkg.github.com/linkedin/Hoptimator"
credentials {
username = System.getenv('GITHUB_ACTOR')
password = System.getenv('GITHUB_TOKEN')
}
}
}
publications {
maven(MavenPublication) {
groupId = 'com.linkedin.hoptimator'
artifactId = 'hoptimator-planner'
from components.java
}
}
}

tasks.withType(JavaCompile) {
options.compilerArgs << '-Xlint:deprecation'
options.compilerArgs << '-Xlint:unchecked'
Expand Down

0 comments on commit 12ffab6

Please sign in to comment.