Skip to content
Snippets Groups Projects
Commit 8fa92ed6 authored by Daniel Stonier's avatar Daniel Stonier
Browse files

hacking on the ros plugin, but can't get the uploadArchives right.

parent a24eb7b8
No related branches found
No related tags found
No related merge requests found
......@@ -11,7 +11,7 @@ project(rosjava_bootstrap)
find_package(catkin REQUIRED rosjava_build_tools)
catkin_rosjava_setup(install)
catkin_rosjava_setup(uploadArchives)
catkin_package()
......@@ -19,4 +19,5 @@ catkin_package()
# Installation
##############################################################################
# Todo
\ No newline at end of file
install(DIRECTORY ${CATKIN_DEVEL_PREFIX}/${CATKIN_GLOBAL_MAVEN_DESTINATION}/ros/rosjava_bootstrap/
DESTINATION ${CATKIN_GLOBAL_MAVEN_DESTINATION}/ros/rosjava_bootstrap)
\ No newline at end of file
......@@ -18,6 +18,11 @@ task wrapper(type: Wrapper) {
gradleVersion = '1.7'
}
project.ext {
/* the ros plugin defines this, but since we're building the plugin... */
rosMavenDeploymentPath = "$System.env.ROS_MAVEN_DEPLOYMENT_PATH"
}
allprojects {
group='org.ros.rosjava_bootstrap'
......@@ -28,21 +33,23 @@ subprojects {
apply plugin: 'maven'
repositories {
maven {
url 'file://' + project.rosMavenDeploymentPath
}
mavenLocal()
maven {
url 'https://github.com/rosjava/rosjava_mvn_repo/raw/master'
}
}
/*
if ( project.rosMavenDeploymentPath != 'null' && project.rosMavenDeploymentPath != '' ) {
uploadArchives {
repositories {
mavenDeployer {
repository(url: uri('../repo'))
repository(url: 'file://' + project.rosMavenDeploymentPath)
}
}
}
}
*/
}
defaultTasks 'install'
package org.ros.gradle_plugins;
import org.gradle.api.Project;
import org.gradle.api.Plugin;
import org.gradle.api.*;
/*
* Provides information about the ros workspace.
*
* - project.ros.maven : location of local ros maven repository
*
* Use this only once in the root of a multi-project gradle build - it will
* only generate the properties once and share them this way.
*/
class RosPlugin implements Plugin<Project> {
Project project
def void apply(Project project) {
this.project = project
println("RosPlugin")
/* Create project.ros.* property extensions */
project.extensions.create("ros", RosPluginExtension)
project.ros.maven = "$System.env.ROS_MAVEN_DEPLOYMENT_PATH"
if ( project.ros.maven != 'null' && project.ros.maven != '' ) {
uploadArchives {
repositories {
mavenDeployer {
repository(url: 'file://' + project.rosMavenDeploymentPath)
}
}
}
}
}
}
class RosPluginExtension {
String maven
}
implementation-class=org.ros.gradle_plugins.RosPlugin
\ No newline at end of file
......@@ -26,6 +26,8 @@ dependencies {
compile 'org.apache.commons:com.springsource.org.apache.commons.io:1.4.0'
compile 'commons-pool:commons-pool:1.6'
compile 'org.apache.commons:com.springsource.org.apache.commons.lang:2.4.0'
compile project(':gradle_plugins')
}
jar {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment