From 5b97fd3d07e4e69984888a9bd969e2e9cfe1fce0 Mon Sep 17 00:00:00 2001 From: Aaron Riekenberg Date: Fri, 6 May 2022 13:16:57 -0500 Subject: [PATCH 1/3] Disable sources jar from publishing, add -Prelease.useLastTag=true. --- .github/workflows/gradle-publish.yml | 4 ++-- build.gradle.kts | 12 ------------ 2 files changed, 2 insertions(+), 14 deletions(-) diff --git a/.github/workflows/gradle-publish.yml b/.github/workflows/gradle-publish.yml index 9aeb2b8..3f9d86e 100644 --- a/.github/workflows/gradle-publish.yml +++ b/.github/workflows/gradle-publish.yml @@ -32,14 +32,14 @@ jobs: - name: Build with Gradle uses: gradle/gradle-build-action@0d13054264b0bb894ded474f08ebb30921341cee with: - arguments: build + arguments: -Prelease.useLastTag=true build # The USERNAME and TOKEN need to correspond to the credentials environment variables used in # the publishing section of your build.gradle - name: Publish to GitHub Packages uses: gradle/gradle-build-action@0d13054264b0bb894ded474f08ebb30921341cee with: - arguments: publish + arguments: -Prelease.useLastTag=true publish env: USERNAME: ${{ github.actor }} TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/build.gradle.kts b/build.gradle.kts index 93f7397..dd7c9a1 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -69,18 +69,6 @@ java { withSourcesJar() } -publishing { - repositories { - mavenLocal() - } - publications { - register("mavenJava", MavenPublication::class) { - from(components["java"]) - artifact(tasks.findByName("sourcesJar")) - } - } -} - jacoco { toolVersion = "0.8.7" } From 440f6c7bf850c3af209152ecac50a54fab18e5af Mon Sep 17 00:00:00 2001 From: Aaron Riekenberg Date: Fri, 6 May 2022 13:20:27 -0500 Subject: [PATCH 2/3] update build.yml --- .github/workflows/build.yml | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index de2c8c0..aee0285 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -6,14 +6,11 @@ name: PR Validation on: # Triggers the workflow on push or pull request events but only for the main branch pull_request: - branches: [ main ] - - # Allows you to run this workflow manually from the Actions tab - workflow_dispatch: + branches: + - main jobs: build: - runs-on: ubuntu-latest permissions: contents: read From 92b67babde77bd75b8168bae8bb5b4e933b0beef Mon Sep 17 00:00:00 2001 From: Aaron Riekenberg Date: Fri, 6 May 2022 13:24:53 -0500 Subject: [PATCH 3/3] remove comments. --- .github/workflows/build.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index aee0285..be46346 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -2,9 +2,7 @@ name: PR Validation -# Controls when the workflow will run on: - # Triggers the workflow on push or pull request events but only for the main branch pull_request: branches: - main