Skip to content

Commit

Permalink
build: disable snasphot signing
Browse files Browse the repository at this point in the history
  • Loading branch information
manticore-projects committed Dec 28, 2023
1 parent 6c1caff commit e5ba5c7
Show file tree
Hide file tree
Showing 4 changed files with 49 additions and 8 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/gradle.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ jobs:
- name: Build with Gradle
uses: gradle/[email protected]
with:
arguments: build check
arguments: check
# arguments: build check publish
env:
ossrhUsername: ${{ secrets.OSSRH_USERNAME }}
ossrhPassword: ${{ secrets.OSSRH_TOKEN }}
ossrhUsername: ${{ secrets.OSSRHPASSWORD }}
ossrhPassword: ${{ secrets.OSSRHUSERNAME }}
38 changes: 38 additions & 0 deletions .github/workflows/gradle_publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
# This workflow uses actions that are not certified by GitHub.
# They are provided by a third-party and are governed by
# separate terms of service, privacy policy, and support
# documentation.
# This workflow will build a Java project with Gradle and cache/restore any dependencies to improve the workflow execution time
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-java-with-gradle

name: Java CI with Gradle

on:
push:
branches: [ "master" ]

permissions:
contents: read

jobs:
build:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up JDK 11
uses: actions/setup-java@v3
with:
java-version: '11'
distribution: 'temurin'
- name: Build with Gradle
uses: gradle/[email protected]
with:
arguments: publish
# arguments: build check publish
env:
ossrhUsername: ${{ secrets.OSSRHPASSWORD }}
ossrhPassword: ${{ secrets.OSSRHUSERNAME }}
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# [JSqlParser 4.7 Website](https://jsqlparser.github.io/JSqlParser) <img src="src/site/sphinx/_images/logo-no-background.svg" alt="drawing" width="200" align="right"/>
# [JSqlParser 4.8 Website](https://jsqlparser.github.io/JSqlParser) <img src="src/site/sphinx/_images/logo-no-background.svg" alt="drawing" width="200" align="right"/>

![Build Status](https://github.com/JSQLParser/JSqlParser/actions/workflows/maven.yml/badge.svg)

Expand Down
11 changes: 7 additions & 4 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -544,10 +544,9 @@ publishing {
def releasesRepoUrl = "https://oss.sonatype.org/content/repositories/snapshots"
def snapshotsRepoUrl= "https://oss.sonatype.org/service/local/staging/deploy/maven2"
url = version.endsWith('SNAPSHOT') ? snapshotsRepoUrl : releasesRepoUrl
//credentials(PasswordCredentials)
credentials {
username = System.getenv("ossrhUsername")
password = System.getenv("ossrhPassword")
username = System.getenv("OSSRHPASSWORD")
password = System.getenv("OSSRHUSERNAME")
}
}
// maven {
Expand All @@ -563,7 +562,11 @@ signing {
//def signingKey = findProperty("signingKey")
//def signingPassword = findProperty("signingPassword")
//useInMemoryPgpKeys(signingKey, signingPassword)
sign publishing.publications.mavenJava

// don't sign SNAPSHOTS
if (!version.endsWith('SNAPSHOT')) {
sign publishing.publications.mavenJava
}
}

tasks.withType(JavaCompile).configureEach {
Expand Down

0 comments on commit e5ba5c7

Please sign in to comment.