diff --git a/.github/install-gpg.sh b/.github/install-gpg.sh new file mode 100755 index 0000000..b08a3d9 --- /dev/null +++ b/.github/install-gpg.sh @@ -0,0 +1,38 @@ +#!/usr/bin/env bash + +set -euf + +sudo apt-get update +sudo apt-get install -y gnupg haveged + +rm -rf ~/.gnupg +gpg --list-keys + +cat >key-info < + + + ossrh + ${env.OSSRHU} + ${env.OSSRHT} + + + + + gpg + + test-key@postgis.net + + + + sonatype-snapshots + + + sonatype-snapshots + + true + + sonatype-snapshots + https://oss.sonatype.org/content/repositories/snapshots/ + + + + + sonatype-staging + + + sonatype-staging + + true + + sonatype-staging + https://oss.sonatype.org/content/groups/staging/ + + + + + sonatype-releases + + + sonatype-releases + + true + + sonatype-releases + https://oss.sonatype.org/content/groups/public/ + + + + + + diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml new file mode 100644 index 0000000..98de2c1 --- /dev/null +++ b/.github/workflows/main.yml @@ -0,0 +1,61 @@ +name: PostGIS Java CI + +on: [push, pull_request] + +defaults: + run: + shell: bash + +jobs: + build-codebase: + strategy: + matrix: + os: [ubuntu-20.04] + java_version: [8] + maven_version: [3.8.1] + name: Build on OS ${{ matrix.os }} with Maven ${{ matrix.maven_version }} using Zulu ${{ matrix.java_version }} + runs-on: ${{ matrix.os }} + env: + JAVA_HOME: /usr/lib/jvm/zulu${{ matrix.java_version }}-ca-amd64 + MAVEN_HOME: /usr/share/maven + MAVEN_PROPS: -Djavadoc.path=`which javadoc` + PROFILES: gpg,release-sign-artifacts,sonatype-deployment,sonatype-snapshots,sonatype-staging,sonatype-releases + SETTINGS: .github/settings.xml + + steps: + - name: Checkout Source + uses: actions/checkout@v2 + + - name: Install GPG and generate test key + run: .github/install-gpg.sh + + - name: Install Zulu OpenJDK + run: .github/install-zulu${{ matrix.java_version }}.sh + + - name: Install Maven + run: .github/install-maven.sh + + - name: Setup Maven repository cache + uses: actions/cache@v2 + env: + cache-name: m2repo + with: + path: ~/.m2/repository + key: ${{ env.cache-name }}-${{ hashFiles('**/pom.xml') }} + restore-keys: | + ${{ env.cache-name }}- + + - name: Log github.ref + run: echo "${{ github.ref }}" + + - name: Show Maven dependency tree + run: mvn -U -V -s ${{ env.SETTINGS }} -P${{ env.PROFILES }} ${{ env.MAVEN_PROPS }} dependency:tree + + - name: Show Maven active profiles + run: mvn -U -V -s ${{ env.SETTINGS }} -P${{ env.PROFILES }} ${{ env.MAVEN_PROPS }} help:active-profiles + + - name: Show Maven effective POM + run: mvn -U -V -s ${{ env.SETTINGS }} -P${{ env.PROFILES }} ${{ env.MAVEN_PROPS }} help:effective-pom + + - name: Maven build/test + run: mvn -U -V -s ${{ env.SETTINGS }} -P${{ env.PROFILES }} ${{ env.MAVEN_PROPS }} clean install diff --git a/.travis.yml b/.travis.yml.disabled similarity index 100% rename from .travis.yml rename to .travis.yml.disabled diff --git a/pom.xml b/pom.xml index ae293bf..e903409 100644 --- a/pom.xml +++ b/pom.xml @@ -86,14 +86,10 @@ https://github.com/postgis/postgis-java/issues - - ossrh - https://oss.sonatype.org/content/repositories/snapshots - - - ossrh - https://oss.sonatype.org/service/local/staging/deploy/maven2/ - + + local-staging-site + http://local-staging/ + @@ -108,7 +104,7 @@ false 1 true - postgis/postgis:12-3.0-alpine + postgis/postgis:13-3.1-alpine postgis1 postgis1 postgis1 @@ -145,13 +141,13 @@ 3.2.3 2.7 - 8.31 + 8.42 1.18.1 1.2.3 42.2.11 1.7.30 0.7 - 1.13.0 + 1.15.3 6.14.3 @@ -472,6 +468,18 @@ + + + windows-javadoc + + + windows + + + + ${java.home}/bin/javadoc.exe + + check-versions @@ -569,7 +577,20 @@ - + + sonatype-deployment + + + ossrh + https://oss.sonatype.org/content/repositories/snapshots + + + ossrh + https://oss.sonatype.org/service/local/staging/deploy/maven2/ + + + + SkipUnitTests