File tree 3 files changed +33
-24
lines changed
3 files changed +33
-24
lines changed Original file line number Diff line number Diff line change 20
20
name : Build project and publish release
21
21
runs-on : ubuntu-latest
22
22
steps :
23
- - uses : actions/checkout@v2
23
+ - uses : actions/checkout@v3
24
24
- name : Set up JDK 1.8
25
- uses : actions/setup-java@v1
25
+ uses : actions/setup-java@v3
26
26
with :
27
27
java-version : 1.8
28
28
server-id : ossrh-release
37
37
run : mvn -B package --file pom.xml
38
38
- name : Publish to Maven central
39
39
if : ${{ !endsWith(steps.project.outputs.version, '-SNAPSHOT') }}
40
- run : mvn --batch-mode -Dgpg.passphrase=${{ secrets.MAVEN_GPG_PASSPHRASE }} deploy --file pom.xml
40
+ run : mvn -B deploy --file pom.xml -Pgpg-sign
41
41
env :
42
42
MAVEN_USERNAME : ${{ secrets.OSSRH_USERNAME }}
43
43
MAVEN_PASSWORD : ${{ secrets.OSSRH_TOKEN }}
Original file line number Diff line number Diff line change 31
31
run : echo ::set-output name=version::$(mvn help:evaluate -Dexpression=project.version -q -DforceStdout)
32
32
- name : Publish to snapshot repo
33
33
if : ${{ endsWith(steps.project.outputs.version, '-SNAPSHOT') }}
34
- run : mvn clean --batch-mode -Dgpg.passphrase=${{ secrets.MAVEN_GPG_PASSPHRASE }} deploy
34
+ run : mvn -B deploy --file pom.xml -Pgpg-sign
35
35
env :
36
36
MAVEN_USERNAME : ${{ secrets.OSSRH_USERNAME }}
37
37
MAVEN_PASSWORD : ${{ secrets.OSSRH_TOKEN }}
Original file line number Diff line number Diff line change 155
155
</execution >
156
156
</executions >
157
157
</plugin >
158
- <plugin >
159
- <groupId >org.apache.maven.plugins</groupId >
160
- <artifactId >maven-gpg-plugin</artifactId >
161
- <version >1.6</version >
162
- <configuration >
163
- <gpgArguments >
164
- <arg >--pinentry-mode</arg >
165
- <arg >loopback</arg >
166
- </gpgArguments >
167
- </configuration >
168
- <executions >
169
- <execution >
170
- <id >sign-artifacts</id >
171
- <phase >verify</phase >
172
- <goals >
173
- <goal >sign</goal >
174
- </goals >
175
- </execution >
176
- </executions >
177
- </plugin >
178
158
<plugin >
179
159
<groupId >org.apache.maven.plugins</groupId >
180
160
<artifactId >maven-source-plugin</artifactId >
244
224
<developerConnection >scm:git:ssh://github.com/aws/random-cut-forest-by-aws.git</developerConnection >
245
225
<url >https://github.com/aws/random-cut-forest-by-aws/tree/main</url >
246
226
</scm >
227
+ <profiles >
228
+ <profile >
229
+ <id >gpg-sign</id >
230
+ <build >
231
+ <plugins >
232
+ <plugin >
233
+ <groupId >org.apache.maven.plugins</groupId >
234
+ <artifactId >maven-gpg-plugin</artifactId >
235
+ <version >3.0.1</version >
236
+ <executions >
237
+ <execution >
238
+ <id >sign-artifacts</id >
239
+ <phase >verify</phase >
240
+ <goals >
241
+ <goal >sign</goal >
242
+ </goals >
243
+ <configuration >
244
+ <gpgArguments >
245
+ <arg >--pinentry-mode</arg >
246
+ <arg >loopback</arg >
247
+ </gpgArguments >
248
+ </configuration >
249
+ </execution >
250
+ </executions >
251
+ </plugin >
252
+ </plugins >
253
+ </build >
254
+ </profile >
255
+ </profiles >
247
256
</project >
You can’t perform that action at this time.
0 commit comments