fixed crosscompile plugin. simplified POM management

This commit is contained in:
nathan 2018-07-17 21:42:38 +02:00
parent 4e0a24da6a
commit ce74db2185

View File

@ -15,27 +15,19 @@
*/ */
import java.time.Instant import java.time.Instant
buildscript {
repositories {
mavenLocal()
}
dependencies {
classpath 'com.dorkbox:CrossCompile:1.0.0'
}
}
plugins { plugins {
id 'java' id 'java'
id 'maven-publish' id 'maven-publish'
id 'signing' id 'signing'
id "com.dorkbox.Licensing" version "1.1.0"
id "com.dorkbox.CrossCompile" version "1.0.0"
} }
apply from: '../Utilities/gradle/swt.gradle' apply from: '../Utilities/gradle/swt.gradle'
apply plugin: 'com.dorkbox.CrossCompile'
apply plugin: 'signing'
group = 'com.dorkbox' group = 'com.dorkbox'
version = '3.13-SNAPSHOT' version = '3.14'
description = 'Cross-platform SystemTray support for Swing/AWT, GtkStatusIcon, and AppIndicator on Java 6+' description = 'Cross-platform SystemTray support for Swing/AWT, GtkStatusIcon, and AppIndicator on Java 6+'
static String[] javaFile(String... fileNames) { static String[] javaFile(String... fileNames) {
@ -391,17 +383,17 @@ publishing {
// remove the Utilities project from the pom (since we include the relevant source, a custom jar is not necessary) // remove the Utilities project from the pom (since we include the relevant source, a custom jar is not necessary)
// This is run AFTER the pom data is put together, and just before written to disk // This is run AFTER the pom data is put together, and just before written to disk
withXml { withXml {
// get the backing list of all the dependencies in the POM def root = asNode()
def depsNode = asNode().getByName('dependencies').get(0).children()
for (int i = 0; i < depsNode.size(); i++) { root.dependencies.'*'.findAll() {
// find and remove the 'Utilities' project from the POM it.artifactId.text() == "Utilities"
if (depsNode.get(i).getByName('artifactId').get(0).children().get(0) == 'Utilities') { }.each() {
depsNode.remove(i) it.parent().remove(it)
break
}
} }
} }
url = 'https://git.dorkbox.com/dorkbox/SystemTray' url = 'https://git.dorkbox.com/dorkbox/SystemTray'
description = this.description description = this.description