Skip to content

Commit 1a87a3f

Browse files
committed
[skip ci] CI automation
1 parent 2a83465 commit 1a87a3f

File tree

2 files changed

+77
-76
lines changed

2 files changed

+77
-76
lines changed

.github/workflows/publish.yml

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7,24 +7,28 @@ jobs:
77
runs-on: ubuntu-latest
88
steps:
99
- uses: actions/checkout@v2
10-
- name: Set up JDK 11
10+
- name: Set up Maven Central Repository
1111
uses: actions/setup-java@v2
1212
with:
1313
java-version: '11'
1414
distribution: 'adopt'
15+
server-id: ossrh
16+
server-username: MAVEN_USERNAME
17+
server-password: MAVEN_PASSWORD
1518
- name: Build project
1619
run: mvn -B -ntp package
1720
- name: Get the tag name
1821
run: echo "TAG=${GITHUB_REF/refs\/tags\//}" >> $GITHUB_ENV
1922
- name: Set version from git tag
2023
run: mvn -B -ntp versions:set -DgenerateBackupPoms=false -DnewVersion="$TAG"
21-
- name: Generate GPG key
22-
run: sh ./.github/generate_gpg_key.sh
23-
env:
24-
GPG_PASS_PHRASE: ${{ secrets.GPG_PASS_PHRASE }}
24+
# - name: Generate GPG key
25+
# run: sh ./.github/generate_gpg_key.sh
26+
# env:
27+
# GPG_PASS_PHRASE: ${{ secrets.GPG_PASS_PHRASE }}
2528
- name: Publish package
26-
run: mvn -B -ntp deploy -s .github/ossrhSettings.xml -P ossrh -Dgpg.passphrase=thephrase
29+
run: mvn --batch-mode deploy
2730
env:
31+
MAVEN_USERNAME: ${{ secrets.OSSRH_USERNAME }}
2832
MAVEN_PASSWORD: ${{ secrets.OSSRH_PASSWORD }}
2933
- name: Build docker init container
3034
run: sh ./build-init-container.sh $TAG

pom.xml

Lines changed: 67 additions & 70 deletions
Original file line numberDiff line numberDiff line change
@@ -49,12 +49,9 @@
4949
</scm>
5050

5151
<distributionManagement>
52-
<snapshotRepository>
53-
<id>ossrh</id>
54-
<url>https://oss.sonatype.org/content/repositories/snapshots</url>
55-
</snapshotRepository>
5652
<repository>
5753
<id>ossrh</id>
54+
<name>Central Repository OSSRH</name>
5855
<url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
5956
</repository>
6057
</distributionManagement>
@@ -193,71 +190,71 @@
193190
</plugins>
194191
</build>
195192
</profile>
196-
<profile>
197-
<id>ossrh</id>
198-
<build>
199-
<plugins>
200-
<plugin>
201-
<groupId>org.apache.maven.plugins</groupId>
202-
<artifactId>maven-compiler-plugin</artifactId>
203-
<version>${maven-compiler-plugin.version}</version>
204-
<configuration>
205-
<source>${maven.compiler.source}</source>
206-
<target>${maven.compiler.target}</target>
207-
</configuration>
208-
</plugin>
209-
<plugin>
210-
<groupId>org.apache.maven.plugins</groupId>
211-
<artifactId>maven-javadoc-plugin</artifactId>
212-
<version>${maven-javadoc-plugin.version}</version>
213-
<configuration>
214-
<sourcepath>src/main/java</sourcepath>
215-
</configuration>
216-
<executions>
217-
<execution>
218-
<id>attach-javadocs</id>
219-
<goals>
220-
<goal>jar</goal>
221-
</goals>
222-
</execution>
223-
</executions>
224-
</plugin>
225-
<plugin>
226-
<groupId>org.apache.maven.plugins</groupId>
227-
<artifactId>maven-source-plugin</artifactId>
228-
<version>${maven-source-plugin.version}</version>
229-
<executions>
230-
<execution>
231-
<id>attach-sources</id>
232-
<goals>
233-
<goal>jar-no-fork</goal>
234-
</goals>
235-
</execution>
236-
</executions>
237-
</plugin>
238-
<plugin>
239-
<groupId>org.apache.maven.plugins</groupId>
240-
<artifactId>maven-gpg-plugin</artifactId>
241-
<version>${maven-gpg-plugin.version}</version>
242-
<configuration>
243-
<!-- Prevent gpg from using pinentry programs -->
244-
<gpgArguments>
245-
<arg>--pinentry-mode</arg>
246-
<arg>loopback</arg>
247-
</gpgArguments>
248-
</configuration>
249-
<executions>
250-
<execution>
251-
<id>sign-artifacts</id>
252-
<phase>verify</phase>
253-
<goals>
254-
<goal>sign</goal>
255-
</goals>
256-
</execution>
257-
</executions>
258-
</plugin>
259-
</plugins>
260-
</build>
261-
</profile>
193+
<!-- <profile>-->
194+
<!-- <id>ossrh</id>-->
195+
<!-- <build>-->
196+
<!-- <plugins>-->
197+
<!-- <plugin>-->
198+
<!-- <groupId>org.apache.maven.plugins</groupId>-->
199+
<!-- <artifactId>maven-compiler-plugin</artifactId>-->
200+
<!-- <version>${maven-compiler-plugin.version}</version>-->
201+
<!-- <configuration>-->
202+
<!-- <source>${maven.compiler.source}</source>-->
203+
<!-- <target>${maven.compiler.target}</target>-->
204+
<!-- </configuration>-->
205+
<!-- </plugin>-->
206+
<!-- <plugin>-->
207+
<!-- <groupId>org.apache.maven.plugins</groupId>-->
208+
<!-- <artifactId>maven-javadoc-plugin</artifactId>-->
209+
<!-- <version>${maven-javadoc-plugin.version}</version>-->
210+
<!-- <configuration>-->
211+
<!-- <sourcepath>src/main/java</sourcepath>-->
212+
<!-- </configuration>-->
213+
<!-- <executions>-->
214+
<!-- <execution>-->
215+
<!-- <id>attach-javadocs</id>-->
216+
<!-- <goals>-->
217+
<!-- <goal>jar</goal>-->
218+
<!-- </goals>-->
219+
<!-- </execution>-->
220+
<!-- </executions>-->
221+
<!-- </plugin>-->
222+
<!-- <plugin>-->
223+
<!-- <groupId>org.apache.maven.plugins</groupId>-->
224+
<!-- <artifactId>maven-source-plugin</artifactId>-->
225+
<!-- <version>${maven-source-plugin.version}</version>-->
226+
<!-- <executions>-->
227+
<!-- <execution>-->
228+
<!-- <id>attach-sources</id>-->
229+
<!-- <goals>-->
230+
<!-- <goal>jar-no-fork</goal>-->
231+
<!-- </goals>-->
232+
<!-- </execution>-->
233+
<!-- </executions>-->
234+
<!-- </plugin>-->
235+
<!-- <plugin>-->
236+
<!-- <groupId>org.apache.maven.plugins</groupId>-->
237+
<!-- <artifactId>maven-gpg-plugin</artifactId>-->
238+
<!-- <version>${maven-gpg-plugin.version}</version>-->
239+
<!-- <configuration>-->
240+
<!-- &lt;!&ndash; Prevent gpg from using pinentry programs &ndash;&gt;-->
241+
<!-- <gpgArguments>-->
242+
<!-- <arg>&#45;&#45;pinentry-mode</arg>-->
243+
<!-- <arg>loopback</arg>-->
244+
<!-- </gpgArguments>-->
245+
<!-- </configuration>-->
246+
<!-- <executions>-->
247+
<!-- <execution>-->
248+
<!-- <id>sign-artifacts</id>-->
249+
<!-- <phase>verify</phase>-->
250+
<!-- <goals>-->
251+
<!-- <goal>sign</goal>-->
252+
<!-- </goals>-->
253+
<!-- </execution>-->
254+
<!-- </executions>-->
255+
<!-- </plugin>-->
256+
<!-- </plugins>-->
257+
<!-- </build>-->
258+
<!-- </profile>-->
262259
</profiles>
263260
</project>

0 commit comments

Comments
 (0)