Skip to content

Commit

Permalink
WIP
Browse files Browse the repository at this point in the history
  • Loading branch information
abelsromero committed Jan 1, 2024
1 parent 7c130f6 commit b8fda09
Show file tree
Hide file tree
Showing 2 changed files with 55 additions and 0 deletions.
26 changes: 26 additions & 0 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -65,3 +65,29 @@ jobs:
maven-version: ${{ matrix.maven }}
- name: Build & Test
run: mvn -B clean javadoc:jar
signature:
environment: test
env:
GPG_KEYNAME: ${{ secrets.GPG_KEYNAME }}
GPG_PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }}
GPG_PRIVATE_KEY: ${{ secrets.GPG_PRIVATE_KEY }}
strategy:
fail-fast: false
matrix:
os:
- ubuntu-latest
java:
- 11
maven:
- 3.9.6
runs-on: ${{ matrix.os }}
steps:
- name: Prepare signature
run: echo -e "$GPG_PRIVATE_KEY" | gpg --import
- uses: s4u/[email protected]
with:
java-distribution: 'temurin'
java-version: ${{ matrix.java }}
maven-version: ${{ matrix.maven }}
- name: Build & Test
run: mvn -B clean install -Psign -DskipTests
29 changes: 29 additions & 0 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -234,6 +234,35 @@
</build>

<profiles>
<profile>
<id>sign</id>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-gpg-plugin</artifactId>
<configuration>
<executable>gpg2</executable>
<keyname>${env.GPG_KEYNAME}</keyname>
<passphrase>${env.GPG_PASSPHRASE}</passphrase>
<gpgArguments>
<arg>--pinentry-mode</arg>
<arg>loopback</arg>
</gpgArguments>
</configuration>
<executions>
<execution>
<id>sign-artifacts</id>
<phase>verify</phase>
<goals>
<goal>sign</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
<profile>
<!--
To release to bintray, add your credentials to ~/.m2/settings.xml and run:
Expand Down

0 comments on commit b8fda09

Please sign in to comment.