Skip to content

Commit

Permalink
feat: fix pom.xml to fix CI for publishing to https://central.sonatyp…
Browse files Browse the repository at this point in the history
…e.com (#35)

* feat: fix pom.xml to fix CI for publishing to https://central.sonatype.com

* fix: modify the password in ci and fix the node version
  • Loading branch information
liewstar authored Oct 2, 2024
1 parent 3539f5c commit dd5af99
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 14 deletions.
9 changes: 7 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,11 @@ jobs:
with:
token: ${{ secrets.CODECOV_TOKEN }}

- name: Set up Node.js
uses: actions/setup-node@v2
with:
node-version: 20

- name: Semantic Release
run: |
npm install -g @conveyal/maven-semantic-release semantic-release
Expand All @@ -81,5 +86,5 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
GPG_KEY_NAME: ${{ secrets.GPG_KEY_NAME }}
GPG_PASSPHRASE: ${{ secrets.GPG_PRIVATE_KEY_PASSWORD }}
OSSRH_JIRA_USERNAME: ${{ secrets.OSSRH_USERNAME }}
OSSRH_JIRA_PASSWORD: ${{ secrets.OSSRH_PASSWORD }}
OSSRH_JIRA_USERNAME: ${{ secrets.OSSRH_JIRA_USERNAME }}
OSSRH_JIRA_PASSWORD: ${{ secrets.OSSRH_JIRA_PASSWORD }}
21 changes: 9 additions & 12 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
<licenses>
<license>
<name>The Apache Software License, Version 2.0</name>
<url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
<url>https://www.apache.org/licenses/LICENSE-2.0.txt</url>
<distribution>repo</distribution>
</license>
</licenses>
Expand Down Expand Up @@ -60,14 +60,11 @@
<distributionManagement>
<snapshotRepository>
<id>ossrh</id>
<url>https://oss.sonatype.org/content/repositories/snapshots</url>
<url>https://central.sonatype.com</url>
</snapshotRepository>
<repository>
<id>ossrh</id>
<url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
</repository>
</distributionManagement>


<build>
<plugins>
<plugin>
Expand Down Expand Up @@ -181,15 +178,15 @@
</plugin>
<plugin>
<!-- Automatically close and deploy from OSSRH -->
<groupId>org.sonatype.plugins</groupId>
<artifactId>nexus-staging-maven-plugin</artifactId>
<version>1.6.7</version>
<groupId>org.sonatype.central</groupId>
<artifactId>central-publishing-maven-plugin</artifactId>
<version>0.5.0</version>
<extensions>true</extensions>
<configuration>
<serverId>ossrh</serverId>
<nexusUrl>https://oss.sonatype.org/</nexusUrl>
<publishingServerId>ossrh</publishingServerId>
<tokenAuth>true</tokenAuth>
<!-- Release versions will be synced to Maven Central automatically. -->
<autoReleaseAfterClose>true</autoReleaseAfterClose>
<autoPublish>true</autoPublish>
</configuration>
</plugin>
</plugins>
Expand Down

0 comments on commit dd5af99

Please sign in to comment.