Skip to content

Commit 630675a

Browse files
committed
chore: Added release & publish GH action
1 parent 973bd60 commit 630675a

2 files changed

Lines changed: 68 additions & 12 deletions

File tree

.github/workflows/release.yml

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
name: Release
2+
3+
on:
4+
workflow_dispatch:
5+
push:
6+
tags:
7+
- "v*"
8+
9+
permissions:
10+
contents: read
11+
12+
jobs:
13+
publish:
14+
name: Publish to Maven Central
15+
runs-on: ubuntu-latest
16+
steps:
17+
- uses: actions/checkout@v4
18+
19+
- name: Set up JDK 11
20+
uses: actions/setup-java@v4
21+
with:
22+
java-version: "11"
23+
distribution: temurin
24+
cache: maven
25+
server-id: central
26+
server-username: CENTRAL_TOKEN_USERNAME
27+
server-password: CENTRAL_TOKEN_PASSWORD
28+
gpg-private-key: ${{ secrets.GPG_PRIVATE_KEY }}
29+
gpg-passphrase: GPG_PASSPHRASE
30+
31+
- name: Build release artifacts
32+
run: mvn --batch-mode clean verify -Dgpg.skip=true
33+
34+
- name: Upload release artifacts
35+
uses: actions/upload-artifact@v4
36+
with:
37+
name: maven-artifacts
38+
path: |
39+
target/*.jar
40+
target/*.pom
41+
42+
- name: Publish to Maven Central
43+
run: mvn --batch-mode deploy -DskipTests
44+
env:
45+
CENTRAL_TOKEN_USERNAME: ${{ secrets.CENTRAL_TOKEN_USERNAME }}
46+
CENTRAL_TOKEN_PASSWORD: ${{ secrets.CENTRAL_TOKEN_PASSWORD }}
47+
GPG_PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }}

pom.xml

Lines changed: 21 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22
<project xmlns="http://maven.apache.org/POM/4.0.0"
3-
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
4-
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
3+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
4+
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
55
<modelVersion>4.0.0</modelVersion>
66

77
<groupId>com.parseable</groupId>
@@ -11,7 +11,7 @@
1111

1212
<name>temporal-parseable</name>
1313
<description>Temporal plugin that exports OpenTelemetry traces and logs directly to Parseable</description>
14-
<url>https://github.com/parseablehq/temporal-plugin-java</url>
14+
<url>https://github.com/parseablehq/parseable-temporal-java</url>
1515

1616
<licenses>
1717
<license>
@@ -23,16 +23,16 @@
2323
<developers>
2424
<developer>
2525
<name>Parseable</name>
26-
<email>engineering@parseable.com</email>
26+
<email>hi@parseable.com</email>
2727
<organization>Parseable</organization>
2828
<organizationUrl>https://parseable.com</organizationUrl>
2929
</developer>
3030
</developers>
3131

3232
<scm>
33-
<connection>scm:git:git://github.com/parseablehq/temporal-plugin-java.git</connection>
34-
<developerConnection>scm:git:ssh://github.com/parseablehq/temporal-plugin-java.git</developerConnection>
35-
<url>https://github.com/parseablehq/temporal-plugin-java/tree/main</url>
33+
<connection>scm:git:git://github.com/parseablehq/parseable-temporal-java.git</connection>
34+
<developerConnection>scm:git:ssh://github.com/parseablehq/parseable-temporal-java.git</developerConnection>
35+
<url>https://github.com/parseablehq/parseable-temporal-java/tree/main</url>
3636
</scm>
3737

3838
<properties>
@@ -172,7 +172,9 @@
172172
<executions>
173173
<execution>
174174
<id>attach-sources</id>
175-
<goals><goal>jar-no-fork</goal></goals>
175+
<goals>
176+
<goal>jar-no-fork</goal>
177+
</goals>
176178
</execution>
177179
</executions>
178180
</plugin>
@@ -183,7 +185,9 @@
183185
<executions>
184186
<execution>
185187
<id>attach-javadocs</id>
186-
<goals><goal>jar</goal></goals>
188+
<goals>
189+
<goal>jar</goal>
190+
</goals>
187191
</execution>
188192
</executions>
189193
</plugin>
@@ -197,7 +201,9 @@
197201
<execution>
198202
<id>sign-artifacts</id>
199203
<phase>verify</phase>
200-
<goals><goal>sign</goal></goals>
204+
<goals>
205+
<goal>sign</goal>
206+
</goals>
201207
</execution>
202208
</executions>
203209
</plugin>
@@ -206,11 +212,12 @@
206212
<plugin>
207213
<groupId>org.sonatype.central</groupId>
208214
<artifactId>central-publishing-maven-plugin</artifactId>
209-
<version>0.7.0</version>
215+
<version>0.11.0</version>
210216
<extensions>true</extensions>
211217
<configuration>
212218
<publishingServerId>central</publishingServerId>
213219
<autoPublish>true</autoPublish>
220+
<waitUntil>published</waitUntil>
214221
</configuration>
215222
</plugin>
216223
<plugin>
@@ -227,7 +234,9 @@
227234
<execution>
228235
<id>validate</id>
229236
<phase>validate</phase>
230-
<goals><goal>check</goal></goals>
237+
<goals>
238+
<goal>check</goal>
239+
</goals>
231240
</execution>
232241
</executions>
233242
</plugin>

0 commit comments

Comments
 (0)