File tree Expand file tree Collapse file tree 1 file changed +47
-0
lines changed
Expand file tree Collapse file tree 1 file changed +47
-0
lines changed Original file line number Diff line number Diff line change 1+ # This workflow will build a Java project with Gradle
2+ # For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-gradle
3+
4+ name : Snapshot Release
5+
6+ on :
7+ push :
8+ tags :
9+ - v[0-9]+.[0-9]+.[0-9]+-SNAPSHOT
10+ - v[0-9]+.[0-9]+.[0-9]+-[0-9a-zA-Z]+-SNAPSHOT
11+ - v[0-9]+.[0-9]+.[0-9]+-[0-9a-zA-Z]+-[0-9a-zA-Z]+-SNAPSHOT
12+ env :
13+ NEXUS_USERNAME : ${{ secrets.NEXUS_USERNAME }}
14+ NEXUS_PASSWORD : ${{ secrets.NEXUS_PASSWORD }}
15+
16+ jobs :
17+ release :
18+ runs-on : ubuntu-latest
19+ steps :
20+ - name : Cancel previous workflow runs
21+ uses : styfle/cancel-workflow-action@0.9.1
22+ with :
23+ access_token : ${{ github.token }}
24+
25+ - name : Checkout 🛎️
26+ uses : actions/checkout@v2
27+ with :
28+ fetch-depth : 2
29+
30+ - name : Set up JDK 11
31+ uses : actions/setup-java@v1
32+ with :
33+ java-version : 11
34+
35+ - name : Grant execute permission for gradlew
36+ run : chmod +x gradlew
37+
38+ - name : Run unit tests with Gradle
39+ run : ./gradlew :opensrp-reporting:clean :opensrp-reporting:testDebugUnitTest --stacktrace
40+
41+ - name : Generate & upload library snapshot artifact AAR (Android Archive) file
42+ run : ./gradlew :opensrp-reporting:uploadArchives -PmavenLocal=false --stacktrace -PsonatypeUsername=${{ secrets.NEXUS_USERNAME }} -PsonatypePassword=${{ secrets.NEXUS_PASSWORD }}
43+
44+ - name : Github Release
45+ uses : softprops/action-gh-release@v1
46+ with :
47+ prerelease : ${{ contains(github.ref, '-alpha') || contains(github.ref, '-beta') }}
You can’t perform that action at this time.
0 commit comments