-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
67 lines (57 loc) · 2.08 KB
/
build.gradle
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
plugins {
id 'java-gradle-plugin'
id 'com.gradle.plugin-publish' version '1.2.1'
id 'dev.lukebemish.managedversioning' version '1.0.0'
}
group = 'dev.lukebemish.docpatcher'
java {
// I don't feel like dealing with old java...
toolchain.languageVersion = JavaLanguageVersion.of(17)
withSourcesJar()
}
repositories {
mavenCentral()
}
managedVersioning {
versionFile.set rootProject.file('version.properties')
}
managedVersioning.apply()
dependencies {
compileOnly 'org.jetbrains:annotations:24.0.1'
implementation 'net.neoforged.javadoctor:injector-spoon:2.0.10'
implementation 'fr.inria.gforge.spoon:spoon-core:10.4.1'
implementation 'com.google.guava:guava:32.1.2-jre'
implementation 'org.apache.commons:commons-text:1.10.0'
}
processResources {
from rootProject.file("LICENSE")
}
gradlePlugin {
website = 'https://github.com/lukebemishprojects/DocPatcher'
vcsUrl = 'https://github.com/lukebemishprojects/DocPatcher.git'
plugins {
docPatcher {
id = 'dev.lukebemish.docpatcher'
displayName = 'DocPatcher'
description = 'Generates and applies javadoc patches to source files using javadoctor and spoon'
implementationClass = 'dev.lukebemish.docpatcher.plugin.impl.DocPatcherPlugin'
tags.addAll(['javadoc', 'patch'])
}
}
}
jar {
manifest {
attributes['Specification-Title'] = 'DocPatcher'
attributes['Specification-Version'] = version.toString().split('-')[0].split(/\+/)[0]
attributes['Specification-Vendor'] = 'Luke Bemish'
attributes['Implementation-Title'] = 'DocPatcher'
attributes['Implementation-Version'] = version
attributes['Implementation-Vendor'] = 'Luke Bemish'
attributes['Implementation-Commit'] = managedVersioning.hash.get()
attributes['Implementation-Timestampt'] = managedVersioning.timestamp.get()
}
}
if (System.getenv('GRADLE_PLUGIN_KEY')) {
ext['gradle.publish.key'] = System.getenv('GRADLE_PLUGIN_KEY')
ext['gradle.publish.secret'] = System.getenv('GRADLE_PLUGIN_SECRET')
}