From 0f61cbe5b8d9e80f5bb6fac2aa807ada00569a31 Mon Sep 17 00:00:00 2001 From: Michael Weinberger Date: Thu, 16 Feb 2017 20:39:57 +0100 Subject: [PATCH] Added compileOnly to "api" dependencies in plugins. Same as: https://github.com/decebals/pf4j/blob/master/demo/api/pom.xml#L32 --- demo_gradle/plugins/plugin1/build.gradle | 16 ++++++++-------- demo_gradle/plugins/plugin2/build.gradle | 2 +- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/demo_gradle/plugins/plugin1/build.gradle b/demo_gradle/plugins/plugin1/build.gradle index 6a9dd89..fc620e6 100644 --- a/demo_gradle/plugins/plugin1/build.gradle +++ b/demo_gradle/plugins/plugin1/build.gradle @@ -1,12 +1,12 @@ jar { - baseName = 'WelcomePlugin' - version = '0.1.0' - manifest { + baseName = 'WelcomePlugin' + version = '0.1.0' + manifest { attributes 'Plugin-Class' : 'ro.fortsoft.pf4j.demo.welcome.WelcomePlugin', - 'Plugin-Id' : 'WelcomePlugin', - 'Plugin-Version' : '1.0.0', - 'Plugin-Provider' : 'Decebal Suiu' - } + 'Plugin-Id' : 'WelcomePlugin', + 'Plugin-Version' : '1.0.0', + 'Plugin-Provider' : 'Decebal Suiu' + } } task plugin(type: Jar) { @@ -23,7 +23,7 @@ task plugin(type: Jar) { assemble.dependsOn plugin dependencies { - compile project(':api') + compileOnly project(':api') // compileOnly important!!! We do not want to put the api into the zip file since the main program has it already! compile 'ro.fortsoft.pf4j:pf4j:1.1.1' compile 'org.apache.commons:commons-lang3:3.0' testCompile group: 'junit', name: 'junit', version: '4.+' diff --git a/demo_gradle/plugins/plugin2/build.gradle b/demo_gradle/plugins/plugin2/build.gradle index 4e380d5..a13bfec 100644 --- a/demo_gradle/plugins/plugin2/build.gradle +++ b/demo_gradle/plugins/plugin2/build.gradle @@ -23,7 +23,7 @@ task plugin(type: Jar) { assemble.dependsOn plugin dependencies { - compile project(':api') + compileOnly project(':api') // compileOnly important!!! We do not want to put the api into the zip file since the main program has it already! compile 'ro.fortsoft.pf4j:pf4j:1.1.1' compile 'org.apache.commons:commons-lang3:3.0' testCompile group: 'junit', name: 'junit', version: '4.+'