@@ -18,13 +18,13 @@ buildscript {
18
18
}
19
19
20
20
plugins {
21
- alias(libs.plugins. dokka)
21
+ ` dokka- convention`
22
22
alias(libs.plugins.kotlinx.binary.compatibility.validator)
23
+ alias(libs.plugins.aws.kotlin.repo.tools.artifactsizemetrics)
23
24
// ensure the correct version of KGP ends up on our buildscript classpath
24
25
// since build-plugins also has <some> version in its dependency closure
25
- alias(libs.plugins.kotlin.multiplatform) apply false
26
- alias(libs.plugins.kotlin.jvm) apply false
27
- alias(libs.plugins.aws.kotlin.repo.tools.artifactsizemetrics)
26
+ id(libs.plugins.kotlin.multiplatform.get().pluginId) apply false
27
+ id(libs.plugins.kotlin.jvm.get().pluginId) apply false
28
28
}
29
29
30
30
artifactSizeMetrics {
@@ -40,35 +40,9 @@ val testJavaVersion = typedProp<String>("test.java.version")?.let {
40
40
}
41
41
42
42
allprojects {
43
- tasks.withType< org.jetbrains.dokka.gradle.AbstractDokkaTask > ().configureEach {
44
- val sdkVersion: String by project
45
- moduleVersion.set(sdkVersion)
46
-
47
- val year = java.time.LocalDate .now().year
48
- val pluginConfigMap = mapOf (
49
- " org.jetbrains.dokka.base.DokkaBase" to """
50
- {
51
- "customStyleSheets": [
52
- "${rootProject.file(" docs/dokka-presets/css/logo-styles.css" )} ",
53
- "${rootProject.file(" docs/dokka-presets/css/aws-styles.css" )} "
54
- ],
55
- "customAssets": [
56
- "${rootProject.file(" docs/dokka-presets/assets/logo-icon.svg" )} ",
57
- "${rootProject.file(" docs/dokka-presets/assets/aws_logo_white_59x35.png" )} ",
58
- "${rootProject.file(" docs/dokka-presets/scripts/accessibility.js" )} "
59
- ],
60
- "footerMessage": "© $year , Amazon Web Services, Inc. or its affiliates. All rights reserved.",
61
- "separateInheritedMembers" : true,
62
- "templatesDir": "${rootProject.file(" docs/dokka-presets/templates" )} "
63
- }
64
- """ ,
65
- )
66
- pluginsMapConfiguration.set(pluginConfigMap)
67
- }
68
-
69
43
if (rootProject.typedProp<Boolean >(" kotlinWarningsAsErrors" ) == true ) {
70
44
tasks.withType< org.jetbrains.kotlin.gradle.tasks.KotlinCompile > {
71
- kotlinOptions .allWarningsAsErrors = true
45
+ compilerOptions .allWarningsAsErrors = true
72
46
}
73
47
}
74
48
@@ -90,27 +64,18 @@ allprojects {
90
64
}
91
65
92
66
// configure the root multimodule docs
93
- tasks.dokkaHtmlMultiModule.configure {
67
+ dokka {
94
68
moduleName.set(" Smithy Kotlin" )
95
69
96
- // Output subprojects' docs to <docs-base>/project-name/* instead of <docs-base>/path/to/project-name/*
97
- // This is especially important for inter-repo linking (e.g., via externalDocumentationLink) because the
98
- // package-list doesn't contain enough project path information to indicate where modules' documentation are
99
- // located.
100
- fileLayout.set { parent, child ->
101
- parent.outputDirectory.dir(child.moduleName)
70
+ dokkaPublications.html {
71
+ includes.from(
72
+ rootProject.file(" docs/dokka-presets/README.md" ),
73
+ )
102
74
}
75
+ }
103
76
104
- includes.from(
105
- // NOTE: these get concatenated
106
- rootProject.file(" docs/dokka-presets/README.md" ),
107
- )
108
-
109
- val excludeFromDocumentation = listOf (
110
- project(" :runtime:testing" ),
111
- project(" :runtime:smithy-test" ),
112
- )
113
- removeChildTasks(excludeFromDocumentation)
77
+ dependencies {
78
+ dokka(project(" :runtime" ))
114
79
}
115
80
116
81
// Publishing
@@ -121,6 +86,7 @@ val lintPaths = listOf(
121
86
" **/*.{kt,kts}" ,
122
87
" !**/generated-src/**" ,
123
88
" !**/smithyprojections/**" ,
89
+ " !**/build/**" ,
124
90
)
125
91
126
92
configureLinting(lintPaths)
0 commit comments