-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle.kts
122 lines (111 loc) · 4.98 KB
/
build.gradle.kts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
/*
* Copyright 2021 Konstantin Gribov
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* https://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
id("plugin-conventions")
kotlin("jvm") version embeddedKotlinVersion
}
@Suppress("UnstableApiUsage")
gradlePlugin {
website.set("https://github.com/grossws/private-repo")
vcsUrl.set("https://github.com/grossws/private-repo.git")
plugins.create("privateRepo") {
id = "ws.gross.private-repo"
displayName = "Settings plugin for private repository configuration and bootstrapping"
description = """
Gradle Settings plugin to configure dependencyResolutionManagement and pluginManagement
to use private Nexus/Artifactory repository with auth and convenient defaults.
""".trimIndent()
implementationClass = "ws.gross.gradle.PrivateRepoPlugin"
tags.set(listOf("repository", "private-repository", "nexus", "artifactory"))
}
plugins.create("privateRepoBase") {
id = "ws.gross.private-repo.base"
displayName = "Settings helper plugin to register privateRepo extension"
description = """
Gradle Settings plugin to register privateRepo extension.
Used by other settings plugins.
""".trimIndent()
implementationClass = "ws.gross.gradle.PrivateRepoBasePlugin"
tags.set(listOf("repository", "private-repository", "nexus", "artifactory"))
}
plugins.create("privateRepoBootstrap") {
id = "ws.gross.private-repo.bootstrap"
displayName = "Settings plugin to apply bootstrap manifests"
description = """
Gradle Settings plugin to apply bootstrap manifests for this build.
Resolves and parses manifest, adds plugin declaration to pluginManagement
and version catalogs to dependencyResolutionManagement.
""".trimIndent()
implementationClass = "ws.gross.gradle.BootstrapPlugin"
tags.set(listOf("repository", "private-repository", "bootstrap"))
}
plugins.create("privateRepoPublish") {
id = "ws.gross.private-repo-publish"
displayName = "Plugin for private repository publication configuration"
description = """
Gradle plugin to configure `maven-publish` plugin with sane default repositories
to use with private Nexus/Artifactory authenticated repo.
""".trimIndent()
implementationClass = "ws.gross.gradle.PrivateRepoPublishPlugin"
tags.set(listOf("repository", "private-repository", "nexus", "artifactory", "publish", "maven-publish"))
}
plugins.create("bootstrapManifest") {
id = "ws.gross.bootstrap-manifest"
displayName = "Plugin to generate and publish bootstrap manifest to configure plugins and version catalogs"
description = """
Gradle plugin to generate bootstrap manifest files (properties file with pluginIds, catalogIds
and version fields) to use with nexusBootstrap feature in private-repo plugin.
Also configures manifest publication.
""".trimIndent()
implementationClass = "ws.gross.gradle.BootstrapManifestPlugin"
tags.set(listOf("bootstrap", "version-catalogs", "plugins", "private-repository"))
}
plugins.create("releaseApprove") {
id = "ws.gross.release-approve"
displayName = "Plugin to add approve task for `nebula.release` plugin rc/final release tasks"
description = """
Gradle plugin which adds approve for rc/final tasks when `nebula.release` plugin present.
Use `-Prelease.approve=true` in non-interactive context.
""".trimIndent()
implementationClass = "ws.gross.gradle.ReleaseApprovePlugin"
tags.set(listOf("release", "git", "nebula-release"))
}
}
@Suppress("UnstableApiUsage")
testing {
suites {
named<JvmTestSuite>("test") {
dependencies {
implementation(project.dependencies.platform(project.dependencies.kotlin("bom", embeddedKotlinVersion)))
implementation(project.dependencies.create(project.dependencies.kotlin("stdlib-jdk8", embeddedKotlinVersion)))
implementation(project.dependencies.plugin(libs.plugins.nebula.release))
}
}
withType<JvmTestSuite> {
useJUnitJupiter(libs.versions.junit.get())
dependencies {
implementation(project.dependencies.platform(project.dependencies.kotlin("bom", embeddedKotlinVersion)))
implementation(project.dependencies.create(project.dependencies.kotlin("stdlib-jdk8", embeddedKotlinVersion)))
implementation(libs.assertk.jvm)
implementation(libs.kgit)
implementation(project.dependencies.platform(libs.jackson.bom))
implementation(libs.jackson.databind)
implementation(libs.jackson.kotlin)
implementation(libs.jackson.guava)
}
}
}
}