File tree 8 files changed +36
-16
lines changed
8 files changed +36
-16
lines changed Original file line number Diff line number Diff line change @@ -90,3 +90,7 @@ lint/tmp/
90
90
# Note: The docs/ directory is our SOURCE (in MD),
91
91
# and the site/ directory is our TARGET (in HTML)
92
92
site /
93
+ # but the Dokka API Doc is generated into docs/
94
+ # (which is slightly confusing, but helps mkdocs to validate links)
95
+ # so we ignore that here, as it's a built artifact that should not be committed
96
+ docs /use /api /* /**
Original file line number Diff line number Diff line change @@ -20,15 +20,12 @@ set -euox pipefail
20
20
rm -rf site/
21
21
mkdir -p site/
22
22
23
+ # We need to generate the Dokka API Doc into docs/use/api/ *before* running mkdocs,
24
+ # so that it can validate the links to it and make sure that they are not broken.
25
+ ./gradlew dokkaHtml
26
+
23
27
# "install --deploy" is better than "sync", because it checks that the Pipfile.lock
24
28
# is up-to-date with the Pipfile before installing. If it's not, it will fail the
25
29
# installation. This is useful for ensuring strict dependency control during CI.
26
30
pipenv install --deploy
27
- pipenv run mkdocs build
28
-
29
- ./gradlew dokkaHtml
30
- mkdir -p site/api/
31
- mv docs/data-capture site/api/
32
- mv docs/engine site/api/
33
- mv docs/knowledge site/api/
34
- mv docs/workflow site/api/
31
+ pipenv run mkdocs build --strict
Original file line number Diff line number Diff line change @@ -123,7 +123,7 @@ dependencies {
123
123
124
124
tasks.dokkaHtml.configure {
125
125
outputDirectory.set(
126
- file(" ../docs/${Releases .DataCapture .artifactId} /${Releases .DataCapture .version} " ),
126
+ file(" ../docs/use/api/ ${Releases .DataCapture .artifactId} /${Releases .DataCapture .version} " ),
127
127
)
128
128
suppressInheritedMembers.set(true )
129
129
dokkaSourceSets {
Original file line number Diff line number Diff line change 1
1
# API
2
2
3
- * [ Engine] ( / api/engine/1.0.0/)
4
- * [ Data Capture] ( /data-capture/1.1.0/ )
5
- * [ Workflow] ( / api/workflow/0.1.0-alpha04/)
6
- * [ Knowledge] ( / api/knowledge/0.1.0-alpha03/)
3
+ * [ Engine] ( api/engine/1.0.0/index.html )
4
+ * [ Data Capture] ( api /data-capture/1.1.0/index.html )
5
+ * [ Workflow] ( api/workflow/0.1.0-alpha04/index.html )
6
+ * [ Knowledge] ( api/knowledge/0.1.0-alpha03/index.html )
Original file line number Diff line number Diff line change @@ -158,7 +158,9 @@ dependencies {
158
158
}
159
159
160
160
tasks.dokkaHtml.configure {
161
- outputDirectory.set(file(" ../docs/${Releases .Engine .artifactId} /${Releases .Engine .version} " ))
161
+ outputDirectory.set(
162
+ file(" ../docs/use/api/${Releases .Engine .artifactId} /${Releases .Engine .version} " ),
163
+ )
162
164
suppressInheritedMembers.set(true )
163
165
dokkaSourceSets {
164
166
named(" main" ) {
Original file line number Diff line number Diff line change @@ -113,7 +113,7 @@ dependencies {
113
113
114
114
tasks.dokkaHtml.configure {
115
115
outputDirectory.set(
116
- file(" ../docs/${Releases .Knowledge .artifactId} /${Releases .Knowledge .version} " ),
116
+ file(" ../docs/use/api/ ${Releases .Knowledge .artifactId} /${Releases .Knowledge .version} " ),
117
117
)
118
118
suppressInheritedMembers.set(true )
119
119
dokkaSourceSets {
Original file line number Diff line number Diff line change @@ -5,6 +5,7 @@ edit_uri: blob/master/docs/
5
5
copyright : Copyright 2024 The Android FHIR SDK Authors
6
6
7
7
nav :
8
+ - Home : index.md
8
9
- Users :
9
10
- API : use/api.md
10
11
- Contributors :
@@ -36,3 +37,17 @@ plugins:
36
37
- git-revision-date-localized
37
38
- minify :
38
39
minify_html : true
40
+
41
+ # https://www.mkdocs.org/user-guide/configuration/#validation
42
+ # Nota Bene: There is no "error" level in MkDocs, but the build-docs.bash script
43
+ # uses "mkdocs build --strict", which cause MkDocs to abort the build on any warnings.
44
+ validation :
45
+ nav :
46
+ not_found : warn
47
+ absolute_links : warn
48
+ omitted_files : warn
49
+ links :
50
+ anchors : warn
51
+ not_found : warn
52
+ absolute_links : warn
53
+ unrecognized_links : warn
Original file line number Diff line number Diff line change @@ -122,7 +122,9 @@ dependencies {
122
122
}
123
123
124
124
tasks.dokkaHtml.configure {
125
- outputDirectory.set(file(" ../docs/${Releases .Workflow .artifactId} /${Releases .Workflow .version} " ))
125
+ outputDirectory.set(
126
+ file(" ../docs/use/api/${Releases .Workflow .artifactId} /${Releases .Workflow .version} " ),
127
+ )
126
128
suppressInheritedMembers.set(true )
127
129
dokkaSourceSets {
128
130
named(" main" ) {
You can’t perform that action at this time.
0 commit comments