generated from boguszpawlowski/AndroidTemplate
-
Notifications
You must be signed in to change notification settings - Fork 3
40 lines (34 loc) · 1.02 KB
/
publish-snapshot.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
name: Publish Snapshot
on:
workflow_dispatch:
push:
branches:
- main
jobs:
deploy-maven-snapshot:
name: Deploy To Maven Snaphot
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v2
with:
fetch-depth: '0'
- name: Cache Gradle
uses: actions/cache@v2
with:
path: |
~/.gradle/caches/
~/.gradle/wrapper/
key: cache-gradle-${{ hashFiles('**/*.gradle', '**/gradle-wrapper.properties') }}
restore-keys: cache-gradle-
- name: Setup Java 15
uses: actions/setup-java@v1
with:
java-version: '15'
- name: Deploy Snapshot
env:
ORG_GRADLE_PROJECT_mavenCentralUsername: ${{ secrets.SONATYPE_NEXUS_USERNAME }}
ORG_GRADLE_PROJECT_mavenCentralPassword: ${{ secrets.SONATYPE_NEXUS_PASSWORD }}
run: ./gradlew :library:publish --no-daemon --no-parallel --stacktrace
- name: Stop Gradle
run: ./gradlew --stop