Permalink
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
147 lines (127 sloc) 4.1 KB
/*
* SPDX-License-Identifier: Apache-2.0
*
* Copyright 2015-2019 Andres Almiray
*
* 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
*
* http://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 'com.gradle.build-scan' version '2.1'
id 'org.kordamp.gradle.kordamp-parentpom' version '1.2.1'
id 'org.kordamp.gradle.source-xref' version '0.12.0'
id 'com.google.osdetector' version '1.6.1'
id 'org.jonnyzzz.java9c' version '0.2.3' apply false
id 'org.javamodularity.moduleplugin' version '1.4.0' apply false
}
buildScan {
termsOfServiceUrl = 'https://gradle.com/terms-of-service'
termsOfServiceAgree = 'yes'
}
ext.platform = osdetector.os == 'osx' ? 'mac' : osdetector.os == 'windows' ? 'win' : osdetector.os
config {
info {
name = 'Ikonli'
description = 'Icon packs for Java applications'
inceptionYear = '2015'
tags = ['icons', 'javafx', 'swing']
specification { enabled = false }
credentials {
sonatype {
username = project.sonatypeUsername
password = project.sonatypePassword
}
}
}
apidoc {
enabled = false
}
sourceHtml {
overview {
stylesheet = project(':guide').file('src/javadoc/resources/css/stylesheet.css')
}
}
sourceXref {
inputEncoding = 'UTF-8'
}
javadoc {
excludes = ['**/*.html', 'META-INF/**']
options {
links('http://docs.oracle.com/javase/8/docs/api/',
'http://docs.oracle.com/javase/8/javafx/api/')
}
}
}
allprojects {
apply plugin: 'idea'
}
idea {
project {
jdkName '11'
languageLevel '11'
ipr {
withXml { provider ->
def node = provider.asNode()
node.component.find { it.'@name' == 'VcsDirectoryMappings' }?.mapping[0].'@vcs' = 'Git'
def compilerConfiguration = node.component.find { it.'@name' == 'CompilerConfiguration' }
compilerConfiguration.remove(compilerConfiguration.annotationProcessing)
compilerConfiguration.append(new XmlParser().parseText('''
<annotationProcessing>
<profile default="true" name="Default" enabled="true">
<processorPath useClasspath="true" />
</profile>
</annotationProcessing>'''))
}
}
}
}
subprojects { subproj ->
if (!subproj.name.contains('guide')) {
apply plugin: 'java'
apply plugin: 'org.jonnyzzz.java9c'
apply plugin: 'org.javamodularity.moduleplugin'
config {
bintray { enabled = true }
}
dependencies {
testCompile 'junit:junit:4.12'
}
license {
mapping {
fxml = 'XML_STYLE'
}
exclude '**/*.ttf'
exclude '**/*.eot'
exclude '**/*.svg'
exclude '**/*.otf'
exclude '**/*.woff'
exclude '**/*.woff2'
exclude '**/*.css'
exclude '**/*.md'
exclude '**/*.txt'
}
subproj.gradle.addBuildListener(new BuildAdapter() {
@Override
void projectsEvaluated(Gradle gradle) {
subproj.tasks.withType(Jar).each { Jar jar ->
jar.configure {
exclude '**/*.otf'
exclude '**/*.eot'
exclude '**/*.svg'
exclude '**/*.woff'
exclude '**/*.woff2'
}
}
}
})
}
}