Skip to content

Commit 135f146

Browse files
authored
Publish documentation (#36)
1 parent c10fcaf commit 135f146

File tree

3 files changed

+66
-0
lines changed

3 files changed

+66
-0
lines changed

.github/workflows/gh-pages.yml

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
name: Publish documentation
2+
3+
on:
4+
push:
5+
branches: [ "main" ]
6+
workflow_dispatch:
7+
8+
permissions:
9+
contents: read
10+
pages: write
11+
id-token: write
12+
13+
concurrency:
14+
group: "pages"
15+
cancel-in-progress: false
16+
17+
jobs:
18+
deploy:
19+
runs-on: ubuntu-latest
20+
21+
environment:
22+
name: github-pages
23+
url: ${{ steps.deployment.outputs.page_url }}
24+
25+
steps:
26+
- name: Checkout
27+
uses: actions/checkout@v5
28+
29+
- name: Set up JDK
30+
uses: actions/setup-java@v5
31+
with:
32+
java-version: "21"
33+
distribution: "corretto"
34+
35+
- name: Setup Gradle
36+
uses: gradle/actions/setup-gradle@v4
37+
38+
- name: Setup Pages
39+
uses: actions/configure-pages@v5
40+
41+
- name: Generate documentation
42+
run: |
43+
./gradlew :dokkaGenerate \
44+
-Pgpr.user=${{ github.repository_owner }} \
45+
-Pgpr.token=${{ secrets.GITHUB_TOKEN }}
46+
47+
- name: Upload artifact
48+
uses: actions/upload-pages-artifact@v3
49+
with:
50+
path: ./docs
51+
52+
- name: Deploy to GitHub Pages
53+
id: deployment
54+
uses: actions/deploy-pages@v4

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,6 @@
22
.idea/
33
.kotlin/
44
build/
5+
docs/
56
.DS_Store
67
local.properties

build.gradle.kts

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,3 +2,14 @@ plugins {
22
`kotlin-dsl` apply false
33
id("io.technoirlab.conventions.root")
44
}
5+
6+
dependencies {
7+
dokka(project(":common-conventions"))
8+
dokka(project(":gradle-plugin-conventions"))
9+
dokka(project(":jvm-conventions"))
10+
dokka(project(":kotlin-multiplatform-conventions"))
11+
dokka(project(":root-conventions"))
12+
dokka(project(":settings-conventions"))
13+
dokka(project(":libraries:gradle-extensions"))
14+
dokka(project(":libraries:gradle-test-kit"))
15+
}

0 commit comments

Comments
 (0)