Skip to content

Commit ff1fbea

Browse files
committed
Properly refractored
1 parent 0022451 commit ff1fbea

2 files changed

Lines changed: 84 additions & 106 deletions

File tree

.github/workflows/release.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ jobs:
4545
MAVEN_CENTRAL_USERNAME: ${{ secrets.OSSRH_USERNAME }}
4646
MAVEN_CENTRAL_PASSWORD: ${{ secrets.OSSRH_PASSWORD }}
4747

48-
- name: Create GitHub release
49-
uses: softprops/action-gh-release@v1
50-
with:
51-
files: target/*.jar
48+
# - name: Create GitHub release
49+
# uses: softprops/action-gh-release@v1
50+
# with:
51+
# files: target/*.jar

pom.xml

Lines changed: 80 additions & 102 deletions
Original file line numberDiff line numberDiff line change
@@ -609,109 +609,87 @@
609609
</plugins>
610610
</build>
611611
</profile>
612-
<profile>
613-
<id>release</id>
614-
<build>
615-
<plugins>
616-
<plugin>
617-
<groupId>org.apache.maven.plugins</groupId>
618-
<artifactId>maven-source-plugin</artifactId>
619-
<version>3.3.0</version>
620-
<executions>
621-
<execution>
622-
<id>attach-sources</id>
623-
<goals>
624-
<goal>jar-no-fork</goal>
625-
</goals>
626-
</execution>
627-
</executions>
628-
</plugin>
629-
<plugin>
630-
<groupId>org.apache.maven.plugins</groupId>
631-
<artifactId>maven-javadoc-plugin</artifactId>
632-
<version>3.6.0</version>
633-
<configuration>
634-
<doclint>none</doclint>
635-
<sourcepath>${project.build.sourceDirectory}:${project.build.directory}/generated-sources/annotations</sourcepath>
636-
</configuration>
637-
<executions>
638-
<execution>
639-
<id>attach-javadocs</id>
640-
<goals>
641-
<goal>jar</goal>
642-
</goals>
643-
</execution>
644-
</executions>
645-
</plugin>
646-
<plugin>
647-
<groupId>org.apache.maven.plugins</groupId>
648-
<artifactId>maven-gpg-plugin</artifactId>
649-
<version>1.6</version>
650-
<executions>
651-
<execution>
652-
<goals>
653-
<!-- Refer: https://maven.apache.org/plugins/maven-gpg-plugin/sign-and-deploy-file-mojo.html -->
654-
<goal>sign-and-deploy-file</goal>
655-
</goals>
656-
<phase>deploy</phase>
657-
<configuration>
658-
<file>${project.build.directory}/${project.build.finalName}.jar</file>
659-
<repositoryId>ossrh</repositoryId>
660-
<url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
661-
<!-- Prevent gpg from using pinentry programs -->
662-
<gpgArguments>
663-
<arg>--pinentry-mode</arg>
664-
<arg>loopback</arg>
665-
</gpgArguments>
666-
<!-- Custom reduced pom file for fat jar -->
667-
<pomFile>${project.basedir}/uber-minimal-pom.xml</pomFile>
668-
<sources>${project.build.directory}/${project.build.finalName}-sources.jar</sources>
669-
<javadoc>${project.build.directory}/${project.build.finalName}-javadoc.jar</javadoc>
670-
<files>${project.build.directory}/${project.build.finalName}-thin.jar</files>
671-
<types>jar</types>
672-
<classifiers>thin</classifiers>
673-
</configuration>
674-
</execution>
675-
</executions>
676-
</plugin>
677-
<plugin>
678-
<groupId>org.apache.maven.plugins</groupId>
679-
<artifactId>maven-deploy-plugin</artifactId>
680-
<version>2.8.2</version>
612+
<profile>
613+
<id>release</id>
614+
<build>
615+
<plugins>
616+
<plugin>
617+
<groupId>org.apache.maven.plugins</groupId>
618+
<artifactId>maven-source-plugin</artifactId>
619+
<version>3.3.1</version>
620+
<executions>
621+
<execution>
622+
<id>attach-sources</id>
623+
<goals>
624+
<goal>jar-no-fork</goal>
625+
</goals>
626+
</execution>
627+
</executions>
628+
</plugin>
629+
<plugin>
630+
<groupId>org.apache.maven.plugins</groupId>
631+
<artifactId>maven-javadoc-plugin</artifactId>
632+
<version>3.8.0</version>
633+
<configuration>
634+
<doclint>none</doclint>
635+
<sourcepath>${project.build.sourceDirectory}:${project.build.directory}/generated-sources/annotations</sourcepath>
636+
</configuration>
637+
<executions>
638+
<execution>
639+
<id>attach-javadocs</id>
640+
<goals>
641+
<goal>jar</goal>
642+
</goals>
643+
</execution>
644+
</executions>
645+
</plugin>
646+
<plugin>
647+
<groupId>org.apache.maven.plugins</groupId>
648+
<artifactId>maven-gpg-plugin</artifactId>
649+
<version>3.2.7</version>
650+
<executions>
651+
<execution>
652+
<goals>
653+
<!-- Updated to use modern Central Portal instead of OSSRH -->
654+
<goal>sign-and-deploy-file</goal>
655+
</goals>
656+
<phase>deploy</phase>
681657
<configuration>
682-
<skip>true</skip>
658+
<file>${project.build.directory}/${project.build.finalName}.jar</file>
659+
<repositoryId>central</repositoryId>
660+
<url>https://central.sonatype.com/api/v1/publisher</url>
661+
<!-- Prevent gpg from using pinentry programs -->
662+
<gpgArguments>
663+
<arg>--pinentry-mode</arg>
664+
<arg>loopback</arg>
665+
</gpgArguments>
666+
<!-- Custom reduced pom file for fat jar -->
667+
<pomFile>${project.basedir}/uber-minimal-pom.xml</pomFile>
668+
<sources>${project.build.directory}/${project.build.finalName}-sources.jar</sources>
669+
<javadoc>${project.build.directory}/${project.build.finalName}-javadoc.jar</javadoc>
670+
<files>${project.build.directory}/${project.build.finalName}-thin.jar</files>
671+
<types>jar</types>
672+
<classifiers>thin</classifiers>
683673
</configuration>
684-
</plugin>
685-
<!-- <plugin>-->
686-
<!-- <groupId>org.sonatype.plugins</groupId>-->
687-
<!-- <artifactId>nexus-staging-maven-plugin</artifactId>-->
688-
<!-- <version>1.6.13</version>-->
689-
<!-- <extensions>true</extensions>-->
690-
<!-- <configuration>-->
691-
<!-- <serverId>ossrh</serverId>-->
692-
<!-- <nexusUrl>https://oss.sonatype.org/</nexusUrl>-->
693-
<!-- <autoReleaseAfterClose>true</autoReleaseAfterClose>-->
694-
<!-- <skipNexusStagingDeployMojo>true</skipNexusStagingDeployMojo>-->
695-
<!-- </configuration>-->
696-
<!-- <executions>-->
697-
<!-- <execution>-->
698-
<!-- <id>nexus-deploy</id>-->
699-
<!-- <phase>deploy</phase>-->
700-
<!-- <goals>-->
701-
<!-- <goal>close</goal>-->
702-
<!-- <goal>release</goal>-->
703-
<!-- </goals>-->
704-
<!-- </execution>-->
705-
<!-- </executions>-->
706-
<!-- </plugin>-->
707-
</plugins>
708-
</build>
709-
<distributionManagement>
710-
<repository>
711-
<id>ossrh</id>
712-
<url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
713-
</repository>
714-
</distributionManagement>
715-
</profile>
674+
</execution>
675+
</executions>
676+
</plugin>
677+
<plugin>
678+
<groupId>org.apache.maven.plugins</groupId>
679+
<artifactId>maven-deploy-plugin</artifactId>
680+
<version>3.1.3</version>
681+
<configuration>
682+
<skip>true</skip>
683+
</configuration>
684+
</plugin>
685+
</plugins>
686+
</build>
687+
<distributionManagement>
688+
<repository>
689+
<id>central</id>
690+
<url>https://central.sonatype.com/api/v1/publisher</url>
691+
</repository>
692+
</distributionManagement>
693+
</profile>
716694
</profiles>
717695
</project>

0 commit comments

Comments
 (0)