Skip to content

Commit

Permalink
Configure uberjar distribution for release
Browse files Browse the repository at this point in the history
  • Loading branch information
aalmiray committed Aug 8, 2022
1 parent 8a70b5f commit eb591d5
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 8 deletions.
13 changes: 6 additions & 7 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,17 +66,16 @@ jobs:
then
NEXT_VERSION=$COMPUTED_NEXT_VERSION
fi
echo "NEXT_VERSION=$NEXT_VERSION" >> $GITHUB_ENV
./mvnw -B -ntp versions:set versions:commit -DnewVersion=$RELEASE_VERSION
git config --global user.email "41898282+github-actions[bot]@users.noreply.github.com"
git config --global user.name "GitHub Action"
git commit -a -m "🏁 Releasing version $RELEASE_VERSION"
git push origin HEAD:master
echo "RELEASE_VERSION=$RELEASE_VERSION" >> $GITUB_ENV
echo "NEXT_VERSION=$NEXT_VERSION" >> $GITUB_ENV
- name: Build
run: |
./mvnw -B -ntp install
./mvnw -B -ntp install -DskipTests=true
- name: 'Release to Maven Central'
env:
Expand All @@ -88,7 +87,7 @@ jobs:
export MAVEN_OPTS=--illegal-access=permit
./mvnw --no-transfer-progress -B --file pom.xml \
-Drepository.url=https://${{ github.actor }}:${{ secrets.GITHUB_TOKEN }}@github.com/${{ github.repository }}.git \
-Dmaven.site.skip=true -Drelease=true deploy
-Dmaven.site.skip=true -Drelease=true -DskipTests=true deploy
- name: 'Release to GitHub'
env:
Expand All @@ -98,14 +97,14 @@ jobs:
run: |
./mvnw -B -ntp -pl :layrry-aggregator -Pjreleaser jreleaser:full-release
- name: JReleaser output
- name: 'JReleaser output'
if: always()
uses: actions/upload-artifact@v3
with:
name: jreleaser
path: |
out/jreleaser/trace.log
out/jreleaser/output.properties
target/jreleaser/trace.log
target/jreleaser/output.properties
- name: 'Set next version'
run: |
Expand Down
10 changes: 9 additions & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -227,7 +227,7 @@
<plugin>
<groupId>org.jreleaser</groupId>
<artifactId>jreleaser-maven-plugin</artifactId>
<version>1.0.0-M3</version>
<version>1.0.0</version>
<inherited>false</inherited>
<configuration>
<jreleaser>
Expand Down Expand Up @@ -302,6 +302,14 @@
</artifact>
</artifacts>
</layrry>
<layrry-uberjar>
<type>SINGLE_JAR</type>
<artifacts>
<artifact>
<path>layrry-launcher/target/layrry-launcher-{{projectVersion}}-all.jar</path>
</artifact>
</artifacts>
</layrry-uberjar>
</distributions>
</jreleaser>
</configuration>
Expand Down

0 comments on commit eb591d5

Please sign in to comment.