Skip to content

Commit 760731e

Browse files
authored
Update snapshot.yml
1 parent 4d04436 commit 760731e

File tree

1 file changed

+43
-0
lines changed

1 file changed

+43
-0
lines changed

.github/workflows/snapshot.yml

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,44 @@
1+
---
2+
3+
name: Publish Snapshot
4+
5+
on:
6+
push:
7+
branches:
8+
- master
9+
- '[0-9].x'
10+
workflow_dispatch:
11+
12+
jobs:
13+
14+
snapshot:
15+
name: Deploy Snapshot
16+
runs-on: ubuntu-latest
17+
steps:
18+
- uses: actions/checkout@v2
19+
- name: Set up publishing to maven central
20+
uses: actions/setup-java@v2
21+
with:
22+
java-version: '8'
23+
distribution: 'temurin'
24+
server-id: ossrh
25+
server-username: MAVEN_USERNAME
26+
server-password: MAVEN_PASSWORD
27+
- name: Cache dependencies
28+
uses: actions/cache@v2
29+
with:
30+
path: |
31+
~/.m2/repository
32+
/var/cache/apt
33+
key: endtraid-${{hashFiles('**/pom.xml')}}
34+
- name: mvn offline
35+
run: |
36+
mvn -q dependency:go-offline
37+
- name: deploy
38+
run: |
39+
mvn --no-transfer-progress \
40+
-DskipTests deploy -N
41+
env:
42+
MAVEN_USERNAME: ${{secrets.OSSH_USERNAME}}
43+
MAVEN_PASSWORD: ${{secrets.OSSH_TOKEN}}
144

0 commit comments

Comments
 (0)