Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
R
Rosjava Bootstrap Gradle
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
CeTI
ROS
ROS Java Packages
Rosjava Bootstrap Gradle
Commits
4005a567
Commit
4005a567
authored
Sep 11, 2013
by
Daniel Stonier
Browse files
Options
Downloads
Patches
Plain Diff
bugfix the broken chained workspace maven repo chain.
parent
449c2f68
No related branches found
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
gradle_plugins/src/main/groovy/org/ros/gradle_plugins/RosPlugin.groovy
+18
-9
18 additions, 9 deletions
...s/src/main/groovy/org/ros/gradle_plugins/RosPlugin.groovy
with
18 additions
and
9 deletions
gradle_plugins/src/main/groovy/org/ros/gradle_plugins/RosPlugin.groovy
+
18
−
9
View file @
4005a567
...
@@ -7,10 +7,14 @@ import org.gradle.api.*;
...
@@ -7,10 +7,14 @@ import org.gradle.api.*;
/*
/*
* Provides information about the ros workspace.
* Provides information about the ros workspace.
*
*
* - project.ros.maven : location of local ros maven repository
* - project.ros.mavenPath : location of local ros maven repositories (in your chained workspaces)
* - project.ros.mavenDeploymentPath : location of the ros maven repository you will publish to
*
*
* Use this only once in the root of a multi-project gradle build - it will
* It also performs the following actions
* only generate the properties once and share them this way.
*
* - checks and maeks sure the maven plugin is running
* - constructs the sequence of dependant maven repos (local ros maven repos, mavenLocal, external ros maven repo)
* - configures the uploadArchives for artifact deployment to the local ros maven repo (devel/share/maven)
*/
*/
class
RosPlugin
implements
Plugin
<
Project
>
{
class
RosPlugin
implements
Plugin
<
Project
>
{
Project
project
Project
project
...
@@ -22,17 +26,21 @@ class RosPlugin implements Plugin<Project> {
...
@@ -22,17 +26,21 @@ class RosPlugin implements Plugin<Project> {
}
}
/* Create project.ros.* property extensions */
/* Create project.ros.* property extensions */
project
.
extensions
.
create
(
"ros"
,
RosPluginExtension
)
project
.
extensions
.
create
(
"ros"
,
RosPluginExtension
)
project
.
ros
.
maven
=
"$System.env.ROS_MAVEN_DEPLOYMENT_PATH"
project
.
ros
.
mavenPath
=
"$System.env.ROS_MAVEN_PATH"
.
split
(
':'
)
if
(
project
.
ros
.
maven
!=
'null'
&&
project
.
ros
.
maven
!=
''
)
{
project
.
ros
.
mavenDeploymentPath
=
"$System.env.ROS_MAVEN_DEPLOYMENT_PATH"
if
(
project
.
ros
.
mavenDeploymentPath
!=
'null'
&&
project
.
ros
.
mavenDeploymentPath
!=
''
)
{
project
.
uploadArchives
{
project
.
uploadArchives
{
repositories
.
mavenDeployer
{
repositories
.
mavenDeployer
{
repository
(
url:
'file://'
+
project
.
ros
.
maven
)
repository
(
url:
'file://'
+
project
.
ros
.
maven
DeploymentPath
)
}
}
}
}
}
}
def
repoURLs
=
project
.
ros
.
mavenPath
.
collect
{
'file://'
+
it
}
project
.
repositories
{
project
.
repositories
{
repoURLs
.
each
{
p
->
maven
{
maven
{
url
'file://'
+
project
.
ros
.
maven
url
p
}
}
}
mavenLocal
()
mavenLocal
()
maven
{
maven
{
...
@@ -43,5 +51,6 @@ class RosPlugin implements Plugin<Project> {
...
@@ -43,5 +51,6 @@ class RosPlugin implements Plugin<Project> {
}
}
class
RosPluginExtension
{
class
RosPluginExtension
{
String
maven
List
<
String
>
mavenPath
String
mavenDeploymentPath
}
}
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment