File tree 5 files changed +16
-29
lines changed
5 files changed +16
-29
lines changed Original file line number Diff line number Diff line change 11
11
required : true
12
12
type : string
13
13
runs-on :
14
- description : " OS to run the task on"
14
+ description : " OSes to run the task on"
15
15
required : true
16
16
type : string
17
17
checkout-ref :
25
25
required : true
26
26
type : string
27
27
runs-on :
28
- description : " OS to run the task on"
28
+ description : " OSes to run the task on"
29
29
required : true
30
30
type : string
31
31
checkout-ref :
58
58
- name : Checkout the repo
59
59
uses : actions/checkout@v3
60
60
with :
61
- ref : ${{ inputs.checkout-ref || github.event.repository.default_branch }}
61
+ ref : ${{ inputs.checkout-ref || github.ref }}
62
62
63
63
- name : Validate Gradle Wrapper
64
64
uses : gradle/wrapper-validation-action@v1
Original file line number Diff line number Diff line change @@ -30,6 +30,7 @@ permissions:
30
30
jobs :
31
31
32
32
sonatype-release :
33
+ if : github.ref == 'refs/heads/main'
33
34
permissions :
34
35
contents : read
35
36
packages : write
40
41
runs-on : macos-latest # only macOS supports building all Kotlin targets
41
42
gradle-task : >-
42
43
publishAllPublicationsToSonatypeReleaseRepository --stacktrace --no-configuration-cache --no-parallel
43
- checkout-ref : ${{ inputs.checkout-ref || github.event.repository.default_branch }}
44
+ checkout-ref : ${{ inputs.checkout-ref }}
Original file line number Diff line number Diff line change @@ -29,39 +29,23 @@ jobs:
29
29
- name : Checkout the repo
30
30
uses : actions/checkout@v3
31
31
with :
32
- ref : ${{ inputs.checkout-ref || github.event.repository.default_branch }}
33
-
34
- - name : Validate Gradle Wrapper
35
- uses : gradle/wrapper-validation-action@v1
32
+ ref : ${{ inputs.checkout-ref || github.ref }}
36
33
37
34
- name : Setup JDK
38
35
uses : actions/setup-java@v3
39
36
with :
40
37
distribution : temurin
41
38
java-version : 11
42
39
43
- - name : Cache NPM
44
- uses : actions/cache@v3
45
- env :
46
- cache-name : cache-npm
47
- with :
48
- key : ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }}
49
- path : |
50
- ./site/node_modules
51
- restore-keys : |
52
- ${{ runner.os }}-build-${{ env.cache-name }}-
53
- ${{ runner.os }}-build-
54
- ${{ runner.os }}-
55
-
56
- - name : docusaurus build
57
- uses : gradle/gradle-build-action@v2
40
+ - uses : gradle/gradle-build-action@v2
58
41
with :
59
42
gradle-home-cache-cleanup : true
60
- arguments : docusaurusBuild
43
+ arguments : |
44
+ :modules:docs:dokkatooGenerate
61
45
62
- - uses : actions/upload-pages-artifact@v2
46
+ - uses : actions/upload-pages-artifact@v1
63
47
with :
64
- path : ./site/ build
48
+ path : ./modules/docs/ build/dokka/html
65
49
66
50
deploy :
67
51
needs : build
75
59
steps :
76
60
- name : Deploy to GitHub Pages
77
61
id : deployment
78
- uses : actions/deploy-pages@v2
62
+ uses : actions/deploy-pages@v1
Original file line number Diff line number Diff line change 1
1
name : Tests
2
2
3
+
3
4
on :
4
5
workflow_dispatch :
5
6
workflow_call :
6
7
8
+
7
9
concurrency :
8
10
group : " Tests: ${{ github.workflow }} @ ${{ github.event.pull_request.head.label || github.head_ref || github.ref }}"
9
11
cancel-in-progress : true
Original file line number Diff line number Diff line change 37
37
contents : write
38
38
packages : write
39
39
with :
40
- checkout-ref : ${{ inputs.checkout-ref || github.event.repository.default_branch }}
40
+ checkout-ref : ${{ inputs.checkout-ref }}
41
41
42
42
publish-site :
43
43
needs : tests
51
51
packages : write
52
52
pages : write # to deploy to Pages
53
53
with :
54
- checkout-ref : ${{ inputs.checkout-ref || github.event.repository.default_branch }}
54
+ checkout-ref : ${{ inputs.checkout-ref }}
You can’t perform that action at this time.
0 commit comments