Skip to content

Commit 0e0fcc8

Browse files
authored
Create gradle-publish.yml
1 parent c48c5c4 commit 0e0fcc8

1 file changed

Lines changed: 29 additions & 0 deletions

File tree

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
# This workflow uses actions that are not certified by GitHub.
2+
# They are provided by a third-party and are governed by
3+
# separate terms of service, privacy policy, and support
4+
# documentation.
5+
# This workflow will build a package using Gradle and then publish it to GitHub packages when a release is created
6+
# For more information see: https://github.com/actions/setup-java/blob/main/docs/advanced-usage.md#Publishing-using-gradle
7+
8+
name: Gradle Package
9+
10+
on:
11+
release:
12+
types: [created]
13+
14+
jobs:
15+
publish:
16+
runs-on: ubuntu-latest
17+
steps:
18+
- uses: actions/checkout@v2
19+
- name: Set up JDK
20+
uses: actions/setup-java@v1
21+
with:
22+
java-version: 18
23+
- name: Grant execute permission for gradlew
24+
run: chmod +x gradlew
25+
- name: Publish with Gradle
26+
run: ./gradlew build publish
27+
env:
28+
MAVEN_NAME: ${{ secrets.MAVEN_NAME }} # token
29+
MAVEN_TOKEN: ${{ secrets.MAVEN_TOKEN }} # password

0 commit comments

Comments
 (0)