forked from jooby-project/jooby
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild.gradle
More file actions
66 lines (57 loc) · 1.95 KB
/
build.gradle
File metadata and controls
66 lines (57 loc) · 1.95 KB
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
// First, apply the publishing plugin
plugins {
id "maven-publish"
id "com.gradle.plugin-publish" version "0.15.0"
id "java-gradle-plugin"
}
// If your plugin has any external java dependencies, Gradle will attempt to
// download them from JCenter for anyone using the plugins DSL
// so you should probably use JCenter for dependency resolution in your own
// project.
repositories {
mavenLocal()
mavenCentral()
}
def pom = new XmlSlurper().parse(projectDir.toPath().getParent().resolve("pom.xml").toFile())
def joobyVersion = project.properties['joobyVersion'] ?: pom.parent.version
// Unless overridden in the pluginBundle config DSL, the project version will
// be used as your plugin version when publishing
version = "${joobyVersion}"
group = "io.jooby"
dependencies {
implementation "io.jooby:jooby-run:$version"
implementation "io.jooby:jooby-openapi:$version"
}
// Use java-gradle-plugin to generate plugin descriptors and specify plugin ids
gradlePlugin {
plugins {
joobyRun {
id = 'io.jooby.run'
implementationClass = 'io.jooby.gradle.JoobyPlugin'
}
openAPI {
id = 'io.jooby.openAPI'
implementationClass = 'io.jooby.gradle.JoobyPlugin'
}
}
}
// The configuration example below shows the minimum required properties
// configured to publish your plugin to the plugin portal
pluginBundle {
website = 'https://jooby.io'
vcsUrl = 'https://github.com/jooby-project/jooby'
tags = ['jooby', 'run']
description = 'Jooby is a modern, performant and easy to use web framework for Java and Kotlin ' +
'built on top of your favorite web server. The joobyRun task allows to restart your ' +
'application on code changes without exiting the JVM'
plugins {
joobyRun {
// id is captured from java-gradle-plugin configuration
displayName = 'Jooby Run plugin'
}
openAPI {
// id is captured from java-gradle-plugin configuration
displayName = 'Jooby OpenAPI plugin'
}
}
}