Skip to content

Commit

Permalink
bintray publication should work now
Browse files Browse the repository at this point in the history
  • Loading branch information
miho committed Apr 18, 2016
1 parent 2e29f45 commit a2662f3
Show file tree
Hide file tree
Showing 8 changed files with 95 additions and 90 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -53,14 +53,13 @@
import javafx.scene.control.MenuItem;
import javafx.scene.input.MouseEvent;
import javafx.scene.layout.Pane;
import jfxtras.labs.scene.control.window.Window;

import java.io.IOException;
import java.net.URL;
import java.nio.file.Paths;
import java.util.ResourceBundle;
import java.util.logging.Level;
import java.util.logging.Logger;
import jfxtras.scene.control.window.Window;

/**
* FXML Controller class
Expand Down
22 changes: 11 additions & 11 deletions VWorkflows-Demo/vworkflows-demo.gradle
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
apply plugin: 'application'
apply from: rootProject.file('gradle/javafx-plugin.gradle')

mainClassName= 'eu.mihosoft.vrl.workflow.demo.Main'

javafx {
mainClass = mainClassName
}

dependencies {
compile project(':vworkflows-fx')
apply plugin: 'application'
apply from: rootProject.file('gradle/javafx-plugin.gradle')

mainClassName= 'eu.mihosoft.vrl.workflow.demo.Main'

javafx {
mainClass = mainClassName
}

dependencies {
compile project(':vworkflows-fx')
}
18 changes: 4 additions & 14 deletions VWorkflows-FX/vworkflows-fx.gradle
Original file line number Diff line number Diff line change
@@ -1,15 +1,5 @@
repositories {
maven { url 'https://oss.sonatype.org/content/repositories/snapshots' }
}

dependencies {
compile project(':vworkflows-core')

if (project.jdk == 7) {
compile "org.jfxtras:jfxtras-labs:2.2-r6-SNAPSHOT"
} else if (project.jdk == 8) {
compile "org.jfxtras:jfxtras-labs:8.0-r1"
}

compile 'org.apache.commons:commons-math3:3.3'
dependencies {
compile project(':vworkflows-core')

compile 'org.apache.commons:commons-math3:3.3'
}
13 changes: 8 additions & 5 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ buildscript {
classpath 'org.kordamp.gradle:stats-gradle-plugin:0.1.5'
classpath 'com.github.ben-manes:gradle-versions-plugin:0.12.0'
classpath 'net.nemerosa:versioning:1.7+'
classpath 'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.5'
classpath 'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.6'
}
}

Expand All @@ -30,6 +30,7 @@ ext {
jacocoMergeExecFile = "${buildDir}/jacoco/root.exec"
jacocoRootReportPath = "${buildDir}/reports/jacoco/root/"
projectsWithCoverage = []
projectsToPublish = []
}

apply plugin: 'jacoco'
Expand Down Expand Up @@ -107,6 +108,7 @@ subprojects { subproj ->
subproj.apply plugin: 'org.kordamp.gradle.stats'

if (subproj.publishJars.toBoolean()) {

task sourceJar(type: Jar) {
group 'Build'
description 'An archive of the source code'
Expand All @@ -118,6 +120,7 @@ subprojects { subproj ->
subproj.apply from: rootProject.file('gradle/publishing.gradle')
subproj.apply from: rootProject.file('gradle/javafx.gradle')

projectsToPublish << subproj
projectsWithCoverage << subproj

dependencies {
Expand Down Expand Up @@ -188,9 +191,9 @@ coveralls {
}

tasks.coveralls {
group = 'Coverage reports'
description = 'Uploads the aggregated coverage report to Coveralls'
group = 'Coverage reports'
description = 'Uploads the aggregated coverage report to Coveralls'

dependsOn jacocoRootReport
onlyIf { System.env.'CI' }
dependsOn jacocoRootReport
onlyIf { System.env.'CI' }
}
72 changes: 36 additions & 36 deletions gradle/javafx-plugin.gradle
Original file line number Diff line number Diff line change
@@ -1,36 +1,36 @@
/*
* Bootstrap script for the Gradle JavaFX Plugin.
* (based on http://plugins.jasoft.fi/vaadin.plugin)
*
* The script will add the latest version of the plugin to the build script
* dependencies and apply the plugin to the project. If you do not want
* this behavior you can copy and paste the below configuration into your
* own build script and define your own repository and version for the plugin.
*/

buildscript {
File javaHome = new File(System.properties['java.home'])
javaHome = javaHome.name == 'jre' ? javaHome.parentFile : javaHome
String jfxrtLocation = new File("${javaHome}/jre/lib/jfxrt.jar").absolutePath
// JavaFX locations for JDK7, JDK7, JDK8
for (location in ['lib/jfxrt.jar', 'jre/lib/jfxrt.jar', 'jre/lib/ext/jfxrt.jar']) {
File file = new File(javaHome, location)
if (file.exists()) {
jfxrtLocation = file.absolutePath
break
}
}

repositories {
jcenter()
}
dependencies {
classpath 'org.bitbucket.shemnon.javafxplugin:gradle-javafx-plugin:8.1.1'
classpath project.files("${javaHome}/lib/ant-javafx.jar")
classpath project.files(jfxrtLocation)
}
}

if (!project.plugins.findPlugin(org.bitbucket.shemnon.javafxplugin.JavaFXPlugin)) {
project.apply(plugin: org.bitbucket.shemnon.javafxplugin.JavaFXPlugin)
}
/*
* Bootstrap script for the Gradle JavaFX Plugin.
* (based on http://plugins.jasoft.fi/vaadin.plugin)
*
* The script will add the latest version of the plugin to the build script
* dependencies and apply the plugin to the project. If you do not want
* this behavior you can copy and paste the below configuration into your
* own build script and define your own repository and version for the plugin.
*/

buildscript {
File javaHome = new File(System.properties['java.home'])
javaHome = javaHome.name == 'jre' ? javaHome.parentFile : javaHome
String jfxrtLocation = new File("${javaHome}/jre/lib/jfxrt.jar").absolutePath
// JavaFX locations for JDK7, JDK7, JDK8
for (location in ['lib/jfxrt.jar', 'jre/lib/jfxrt.jar', 'jre/lib/ext/jfxrt.jar']) {
File file = new File(javaHome, location)
if (file.exists()) {
jfxrtLocation = file.absolutePath
break
}
}

repositories {
jcenter()
}
dependencies {
classpath 'org.bitbucket.shemnon.javafxplugin:gradle-javafx-plugin:8.1.1'
classpath project.files("${javaHome}/lib/ant-javafx.jar")
classpath project.files(jfxrtLocation)
}
}

if (!project.plugins.findPlugin(org.bitbucket.shemnon.javafxplugin.JavaFXPlugin)) {
project.apply(plugin: org.bitbucket.shemnon.javafxplugin.JavaFXPlugin)
}
26 changes: 22 additions & 4 deletions gradle/publishing.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,23 @@ apply plugin: 'maven-publish'
apply plugin: 'com.jfrog.bintray'
apply plugin: 'net.nemerosa.versioning'

task javadocJar(type: Jar, dependsOn: javadoc) {
classifier = 'javadoc'
from javadoc.destinationDir
}

// create one jar for the source files
task sourcesJar(type: Jar, dependsOn: classes) {
classifier = 'sources'
from sourceSets.main.allSource
}

artifacts {
archives jar
archives javadocJar
archives sourcesJar
}

def pomConfig = {
name project.name
description 'VWorkflows'
Expand Down Expand Up @@ -38,7 +55,8 @@ publishing {
publications {
mavenCustom(MavenPublication) {
from components.java
artifact sourceJar
artifact sourcesJar
artifact javadocJar

pom.withXml {
// all dependencies should use the default scope (compile) but
Expand Down Expand Up @@ -82,12 +100,12 @@ bintray {
key = project.bintrayApiKey
publications = ['mavenCustom']
pkg {
repo = 'maven'
userOrg = 'mihosoft'
repo = 'VWorkflows'
userOrg = 'miho'
name = project.name
desc = project.name
licenses = ['BSD 2-Clause']
labels = ['javafx', 'workoflows']
labels = ['javafx', 'workflows','vrl','vrl-studio', 'graphs','flows', 'visual programming']
websiteUrl = 'https://github.com/miho/VWorkflows'
issueTrackerUrl = 'https://github.com/miho/VWorkflows/issues'
vcsUrl = 'https://github.com/miho/VWorkflows.git'
Expand Down
11 changes: 3 additions & 8 deletions gradle/version-info.gradle
Original file line number Diff line number Diff line change
@@ -1,8 +1,3 @@
// maven deployment properties
if (project.jdk == 8) {
group = 'eu.mihosoft.vrl.workflow-8.0'
} else {
group = 'eu.mihosoft.vrl.workflow'
}

version = '0.1-r2-SNAPSHOT'
// maven deployment properties
group = 'eu.mihosoft.vrl.workflow'
version = '0.2'
20 changes: 10 additions & 10 deletions settings.gradle
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
include 'VWorkflows-Core'
include 'VWorkflows-FX'
include 'VWorkflows-Demo'

rootProject.name = 'VWorkflows'
rootProject.children.each { project ->
String projectDirName = project.name
project.name = project.name.toLowerCase()
project.buildFileName = "${project.name}.gradle"
assert project.buildFile.isFile()
include 'VWorkflows-Core'
include 'VWorkflows-FX'
include 'VWorkflows-Demo'

rootProject.name = 'vworkflows'
rootProject.children.each { project ->
String projectDirName = project.name
project.name = project.name.toLowerCase()
project.buildFileName = "${project.name}.gradle"
assert project.buildFile.isFile()
}

0 comments on commit a2662f3

Please sign in to comment.