Skip to content

Commit 1efecb6

Browse files
committed
DEVOPS: add github package deploy
1 parent 14a930f commit 1efecb6

File tree

2 files changed

+23
-3
lines changed

2 files changed

+23
-3
lines changed

.github/workflows/build_mainline.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
1-
name: Build [mainline]
1+
name: Build [mainline]
22
on:
33
push:
44
branches:
55
- main
6-
- main_**
76

87
jobs:
98
build:
@@ -15,9 +14,10 @@ jobs:
1514

1615
steps:
1716
- uses: actions/checkout@v4
17+
env:
18+
GITHUB_TOKEN: ${{ secrets.REPO_TOKEN }} # Needed to get PR information, if any
1819
with:
1920
ref: ${{ github.head_ref }}
20-
token: ${{ secrets.REPO_TOKEN }}
2121

2222
- name: Set up JDK 21
2323
uses: actions/setup-java@v4

.github/workflows/release.yml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
name: Publish package to GitHub Packages
2+
on:
3+
release:
4+
types: [created]
5+
jobs:
6+
publish:
7+
runs-on: ubuntu-latest
8+
permissions:
9+
contents: read
10+
packages: write
11+
steps:
12+
- uses: actions/checkout@v4
13+
- uses: actions/setup-java@v4
14+
with:
15+
java-version: '21'
16+
distribution: 'temurin'
17+
- name: Publish package
18+
run: mvn --batch-mode deploy
19+
env:
20+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)