File tree Expand file tree Collapse file tree 1 file changed +36
-2
lines changed Expand file tree Collapse file tree 1 file changed +36
-2
lines changed Original file line number Diff line number Diff line change 11name : ci
22
3- on : [push, pull_request]
3+ on : [ push, pull_request ]
44
55jobs :
6- build :
6+ check :
77 runs-on : ubuntu-latest
88
99 steps :
2828 java-version : 1.8
2929
3030 - run : ./gradlew check
31+
32+ publish :
33+ needs : check
34+ if : github.ref == 'refs/heads/master' && github.event_name == 'push' && needs.check.result == 'success'
35+ runs-on : ubuntu-latest
36+
37+ steps :
38+ - uses : actions/checkout@v2
39+
40+ - uses : actions/cache@v1
41+ with :
42+ path : ~/.gradle/wrapper
43+ key : ${{ runner.os }}-gradle-wrapper-${{ hashFiles('gradle/wrapper/gradle-wrapper.*') }}
44+ restore-keys : |
45+ ${{ runner.os }}-gradle-wrapper-
46+
47+ - uses : actions/cache@v1
48+ with :
49+ path : ~/.gradle/caches
50+ key : ${{ runner.os }}-gradle-caches-${{ hashFiles('**/*.gradle.kts') }} }}
51+ restore-keys : |
52+ ${{ runner.os }}-gradle-caches-
53+
54+ - uses : actions/setup-java@v1
55+ with :
56+ java-version : 1.8
57+
58+ - run : ./gradlew publish
59+ env :
60+ ORG_GRADLE_PROJECT_ossrhUsername : ${{ secrets.OSSRH_USERNAME }}
61+ ORG_GRADLE_PROJECT_ossrhPassword : ${{ secrets.OSSRH_PASSWORD }}
62+ ORG_GRADLE_PROJECT_signingKeyId : ${{ secrets.SIGNING_KEY_ID }}
63+ ORG_GRADLE_PROJECT_signingKey : ${{ secrets.SIGNING_KEY }}
64+ ORG_GRADLE_PROJECT_signingPassword : ${{ secrets.SIGNING_PASSWORD }}
You can’t perform that action at this time.
0 commit comments