Skip to content

Commit 2218749

Browse files
Allow Continuous Integration to sign artifacts on its own.
Release process now relies on Orekit Nexus repository. Allow Continuous Integration to sign artifacts on its own.
1 parent 92870ff commit 2218749

File tree

3 files changed

+38
-30
lines changed

3 files changed

+38
-30
lines changed

.CI/maven-settings.xml

Lines changed: 33 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,14 @@
1-
<settings xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
2-
xmlns="http://maven.apache.org/SETTINGS/1.0.0"
3-
xsi:schemalocation="http://maven.apache.org/SETTINGS/1.0.0 http://maven.apache.org/xsd/settings-1.0.0.xsd">
1+
<settings xmlns="http://maven.apache.org/SETTINGS/1.0.0"
2+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
3+
xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0 https://maven.apache.org/xsd/settings-1.0.0.xsd">
4+
<mirrors>
5+
<mirror>
6+
<id>Nexus-Orekit</id>
7+
<name>Maven Repository Manager</name>
8+
<url>https://packages.orekit.org/repository/maven-public/</url>
9+
<mirrorOf>*</mirrorOf>
10+
</mirror>
11+
</mirrors>
412
<servers>
513
<server>
614
<id>ci-releases</id>
@@ -13,4 +21,25 @@
1321
<password>${env.NEXUS_PASSWORD}</password>
1422
</server>
1523
</servers>
16-
</settings>
24+
<profiles>
25+
<profile>
26+
<activation>
27+
<activeByDefault>true</activeByDefault>
28+
</activation>
29+
<repositories>
30+
<repository>
31+
<id>Nexus-Orekit</id>
32+
<name>Nexus Public Repository</name>
33+
<url>https://packages.orekit.org/repository/maven-public/</url>
34+
<releases>
35+
<enabled>true</enabled>
36+
</releases>
37+
<snapshots>
38+
<enabled>true</enabled>
39+
<updatePolicy>always</updatePolicy>
40+
</snapshots>
41+
</repository>
42+
</repositories>
43+
</profile>
44+
</profiles>
45+
</settings>

.github/workflows/maven.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,9 @@ jobs:
3131
SONARQUBE_HOST_URL: ${{ vars.SONARQUBE_HOST_URL }}
3232
- name: Deployment
3333
if: ( github.repository == 'Hipparchus-Math/hipparchus' ) && ( ( github.ref == 'refs/heads/main' ) || startsWith( github.ref, 'refs/heads/release-' ) )
34-
run: mvn -B -U -f pom.xml -s .CI/maven-settings.xml deploy -Pci-deploy -DskipTests=true
34+
run: mvn -B -U -f pom.xml -s .CI/maven-settings.xml deploy -DskipTests=true -Prelease,ci-deploy
3535
env:
3636
NEXUS_USERNAME: ${{ secrets.NEXUS_USERNAME }}
3737
NEXUS_PASSWORD: ${{ secrets.NEXUS_PASSWORD }}
38+
MAVEN_GPG_KEY: ${{ secrets.MAVEN_GPG_KEY }}
39+
MAVEN_GPG_PASSPHRASE: ${{ secrets.MAVEN_GPG_PASSPHRASE }}

hipparchus-parent/pom.xml

Lines changed: 2 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -557,7 +557,6 @@
557557
<hipparchus.maven-surefire-plugin.version>3.5.2</hipparchus.maven-surefire-plugin.version>
558558
<hipparchus.maven-surefire-report-plugin.version>3.5.2</hipparchus.maven-surefire-report-plugin.version>
559559
<hipparchus.maven-enforcer-plugin.version>3.5.0</hipparchus.maven-enforcer-plugin.version>
560-
<hipparchus.nexus-staging-maven-plugin.version>1.7.0</hipparchus.nexus-staging-maven-plugin.version>
561560
<hipparchus.maven-gpg-plugin.version>3.2.7</hipparchus.maven-gpg-plugin.version>
562561
<hipparchus.maven-install-plugin.version>3.1.4</hipparchus.maven-install-plugin.version>
563562
<hipparchus.apache-rat-plugin.version>0.16.1</hipparchus.apache-rat-plugin.version>
@@ -1031,16 +1030,6 @@
10311030
</profile>
10321031
<profile>
10331032
<id>release</id>
1034-
<distributionManagement>
1035-
<snapshotRepository>
1036-
<id>ossrh</id>
1037-
<url>https://oss.sonatype.org/content/repositories/snapshots</url>
1038-
</snapshotRepository>
1039-
<repository>
1040-
<id>ossrh</id>
1041-
<url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
1042-
</repository>
1043-
</distributionManagement>
10441033
<build>
10451034
<plugins>
10461035
<plugin>
@@ -1069,25 +1058,13 @@
10691058
</execution>
10701059
</executions>
10711060
</plugin>
1072-
<plugin>
1073-
<groupId>org.sonatype.plugins</groupId>
1074-
<artifactId>nexus-staging-maven-plugin</artifactId>
1075-
<version>${hipparchus.nexus-staging-maven-plugin.version}</version>
1076-
<extensions>true</extensions>
1077-
<configuration>
1078-
<serverId>ossrh</serverId>
1079-
<nexusUrl>https://oss.sonatype.org/</nexusUrl>
1080-
<autoReleaseAfterClose>false</autoReleaseAfterClose>
1081-
</configuration>
1082-
</plugin>
10831061
<plugin>
10841062
<groupId>org.apache.maven.plugins</groupId>
10851063
<artifactId>maven-gpg-plugin</artifactId>
10861064
<version>${hipparchus.maven-gpg-plugin.version}</version>
10871065
<configuration>
1088-
<gpgArguments>
1089-
<arg>--digest-algo=SHA512</arg>
1090-
</gpgArguments>
1066+
<signer>bc</signer>
1067+
<useAgent>false</useAgent>
10911068
</configuration>
10921069
<executions>
10931070
<execution>

0 commit comments

Comments
 (0)