Skip to content

Commit d11737b

Browse files
committed
Fix release workflow.
Relates to #60
1 parent 1fde84d commit d11737b

2 files changed

Lines changed: 33 additions & 34 deletions

File tree

.github/workflows/release.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,6 @@ jobs:
5252
CENTRAL_USER_TOKEN: ${{ secrets.CENTRAL_USER_TOKEN }}
5353

5454
- name: Publish package to Maven Central
55-
run: mvn clean deploy -Dgpg.skip=false -Dgpg.passphrase="${GPG_PASSPHRASE}" -DskipTests -B
55+
run: mvn clean deploy -Prelease -Dgpg.passphrase="${GPG_PASSPHRASE}" -DskipTests -B
5656
env:
5757
GPG_PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }}

pom.xml

Lines changed: 32 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -208,39 +208,38 @@
208208
<groupId>org.apache.maven.plugins</groupId>
209209
<artifactId>maven-source-plugin</artifactId>
210210
</plugin>
211-
<plugin>
212-
<groupId>org.apache.maven.plugins</groupId>
213-
<artifactId>maven-gpg-plugin</artifactId>
214-
<version>3.0.1</version>
215-
<executions>
216-
<execution>
217-
<id>sign-artifacts</id>
218-
<phase>verify</phase>
219-
<goals>
220-
<goal>sign</goal>
221-
</goals>
222-
<configuration>
223-
<gpgArguments>
224-
<arg>--armor</arg>
225-
<arg>--batch</arg>
226-
<arg>--pinentry-mode</arg>
227-
<arg>loopback</arg>
228-
</gpgArguments>
229-
</configuration>
230-
</execution>
231-
</executions>
232-
</plugin>
233-
<!-- <plugin>-->
234-
<!-- <groupId>org.sonatype.central</groupId>-->
235-
<!-- <artifactId>central-publishing-maven-plugin</artifactId>-->
236-
<!-- <version>0.7.0</version>-->
237-
<!-- <extensions>true</extensions>-->
238-
<!-- <configuration>-->
239-
<!-- <publishingServerId>central</publishingServerId>-->
240-
<!-- <autoPublish>true</autoPublish>-->
241-
<!-- <waitUntil>uploaded</waitUntil>-->
242-
<!-- </configuration>-->
243-
<!-- </plugin>-->
244211
</plugins>
245212
</build>
213+
214+
<profiles>
215+
<profile>
216+
<id>release</id>
217+
<build>
218+
<plugins>
219+
<plugin>
220+
<groupId>org.apache.maven.plugins</groupId>
221+
<artifactId>maven-gpg-plugin</artifactId>
222+
<version>3.0.1</version>
223+
<executions>
224+
<execution>
225+
<id>sign-artifacts</id>
226+
<phase>verify</phase>
227+
<goals>
228+
<goal>sign</goal>
229+
</goals>
230+
<configuration>
231+
<gpgArguments>
232+
<arg>--armor</arg>
233+
<arg>--batch</arg>
234+
<arg>--pinentry-mode</arg>
235+
<arg>loopback</arg>
236+
</gpgArguments>
237+
</configuration>
238+
</execution>
239+
</executions>
240+
</plugin>
241+
</plugins>
242+
</build>
243+
</profile>
244+
</profiles>
246245
</project>

0 commit comments

Comments
 (0)