File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ name : Publish package to the Maven Central Repository
2+
3+ on :
4+ push :
5+ branches :
6+ - main
7+ pull_request :
8+ branches : [ main ]
9+
10+ jobs :
11+ publish :
12+ runs-on : ubuntu-latest
13+ steps :
14+ - uses : actions/checkout@v4
15+ - name : Set up Java
16+ uses : actions/setup-java@v4
17+ with :
18+ java-version : ' 11'
19+ distribution : ' temurin'
20+ - name : Build
21+ run : mvn clean compile
22+ - name : Publish to Maven Central
23+ if : github.ref == 'refs/heads/main' && github.event_name == 'push'
24+ env :
25+ JRELEASER_NEXUS2_USERNAME : ${{ secrets.JRELEASER_NEXUS2_USERNAME }}
26+ JRELEASER_NEXUS2_PASSWORD : ${{ secrets.JRELEASER_NEXUS2_PASSWORD }}
27+ JRELEASER_MAVENCENTRAL_USERNAME : ${{ secrets.JRELEASER_MAVENCENTRAL_USERNAME }}
28+ JRELEASER_MAVENCENTRAL_PASSWORD : ${{ secrets.JRELEASER_MAVENCENTRAL_PASSWORD }}
29+ JRELEASER_GPG_PASSPHRASE : ${{ secrets.JRELEASER_GPG_PASSPHRASE }}
30+ JRELEASER_GPG_SECRET_KEY : ${{ secrets.JRELEASER_GPG_SECRET_KEY }}
31+ JRELEASER_GPG_PUBLIC_KEY : ${{ secrets.JRELEASER_GPG_PUBLIC_KEY }}
32+ JRELEASER_GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
33+ run : mvn -Prelease deploy jreleaser:deploy -Djreleaser.config.file=jreleaser.yml -DaltDeploymentRepository=local::file:./target/staging-deploy -DskipTests
Original file line number Diff line number Diff line change 1+ signing :
2+ active : ALWAYS
3+ armored : true
4+
5+ deploy :
6+ maven :
7+ mavenCentral :
8+ sonatype :
9+ active : RELEASE
10+ url : https://central.sonatype.com/api/v1/publisher
11+ stagingRepositories :
12+ - target/staging-deploy
Original file line number Diff line number Diff line change 66 <artifactId >perun-assets</artifactId >
77 <version >4.0.0-SNAPSHOT</version >
88 <packaging >bundle</packaging >
9-
109 <name >perun-assets</name >
11- <url >http://maven.apache.org</url >
12-
10+ <url >https://github.com/PerunTech/perun-assets</url >
11+ <organization >
12+ <name >Perun Technologies</name >
13+ <url >http://peruntech.org</url >
14+ </organization >
1315 <properties >
1416 <project .build.sourceEncoding>UTF-8</project .build.sourceEncoding>
1517 </properties >
2325 </resource >
2426 </resources >
2527 <plugins >
28+ <plugin >
29+ <groupId >org.jreleaser</groupId >
30+ <artifactId >jreleaser-maven-plugin</artifactId >
31+ <version >1.19.0</version >
32+ <configuration >
33+ <jreleaser >
34+ <signing >
35+ <active >ALWAYS</active >
36+ <armored >true</armored >
37+ </signing >
38+ <deploy >
39+ <maven >
40+ <nexus2 >
41+ <maven-central >
42+ <active >ALWAYS</active >
43+ <url >
44+ https://s01.oss.sonatype.org/service/local</url >
45+ <closeRepository >false</closeRepository >
46+ <releaseRepository >false</releaseRepository >
47+ <stagingRepositories >
48+ target/staging-deploy</stagingRepositories >
49+ </maven-central >
50+ </nexus2 >
51+ </maven >
52+ </deploy >
53+ </jreleaser >
54+ </configuration >
55+ </plugin >
2656 <plugin >
2757 <groupId >org.apache.maven.plugins</groupId >
2858 <artifactId >maven-source-plugin</artifactId >
You can’t perform that action at this time.
0 commit comments