You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@sling.apache.org by ro...@apache.org on 2017/11/07 09:16:42 UTC
[sling-maven-launchpad-plugin] annotated tag
maven-launchpad-plugin-2.2.0 created (now aa136fc)
This is an automated email from the ASF dual-hosted git repository.
rombert pushed a change to annotated tag maven-launchpad-plugin-2.2.0
in repository https://gitbox.apache.org/repos/asf/sling-maven-launchpad-plugin.git.
at aa136fc (tag)
tagging 5c61ac035c2a1487fae73a02e746b874ef63ba19 (commit)
by Carsten Ziegeler
on Fri Nov 16 07:50:24 2012 +0000
- Log -----------------------------------------------------------------
maven-launchpad-plugin-2.2.0
-----------------------------------------------------------------------
This annotated tag includes the following new commits:
new 96dc6d5 Introducing the maven-launchpad-plugin and builder (fka uber) project described in SLING-1197
new ff6a77c SLING-1310 - Changing artifactId of launchpad.builder to launchpad
new 1f5bd24 SLING-1322 - adding check to avoid loading launchpad artifact if it's the same as the current project's
new 347e5fb SLING-1322 - removing extraneous project variable
new b8899de SLING-1323 - adding "bundlesToRemove" option
new 5682b2d Unifying bundle addition / removal code (re: SLING-1321)
new bb29c9b SLING-1351 Fixed, added the Start levels in when there are none defined.
new 8ffdfb1 SLING-1364 - creating prepare-test-webapp mojo
new d2e7962 SLING-1351 When the xpp parser loads a Bundle it only sets the attributes specified on the bundle, and takes no account of any containers, hence on merge the container start level must be inspected to determine where a bundle should be merged. If not specified (ie 0) it should be merged in the containing bundle. This means that its not going to be possible to specify a bundle as loading in start level 0 by setting the level on the bundle. To load in start level 0 you mus [...]
new 8c0ec78 SLING-1441 - adding run goal to launchpad plugin
new b3f5ef2 SLING-1454 - adding ability to read filtered sling properties from a file
new df85fd6 SLING-1442 - adding start and stop goals to launchpad plugin
new 74b72b9 exposing controlHost configuration parameter in launchpad plugin
new 99ee468 fix formatting of pom file
new 9768cfb SLING-1442 - shouldn't be killing the JVM on a "stop" command.
new dd65aa8 SLING-1491 - switching from pax web to felix httpservice
new eb5e840 updating to released launchpad base
new 2183492 reformatting pom
new cc7a04f [maven-release-plugin] prepare release maven-launchpad-plugin-2.0.6
new d69b5db [maven-release-plugin] prepare for next development iteration
new 2e9d194 using next snapshot until release vote is finished
new e75b100 Update some notice files
new 2551177 Use released version of launchpad base
new 917e990 Use released parent pom.
new c6c90d7 SLING-1586 - adding overwrite version on merge code
new 99e00dc SLING-1591 - upgrading to latest base artifacts
new c52ad9c SLING-1692 - replacing dummy code for updated() method.
new 2945145 SLING-1693 - adding xml as a resource provider provided extension
new 42035b5 changing classname and adding missing license header
new 119f700 SLING-1693 - implemeting a search path for resources
new b508767 SLING-1743 / SLING-845 - setting slingHome to default to ${basedir}/sling. No longer need the antrun execution as a result
new ea8d50e SLING-1799 - adding output-bundle-list mojo
new d05a0b4 tabs -> spaces
new f300177 SLING-1795 - adding Drools-based rules for rewriting bundle list. Includes sample rule which can be activated by running "mvn -P test-reactor-sling-bundles clean install" from the root project.
new cbb45d4 updating all modules to parent 10-SNAPSHOT in anticipation of emma additions to parent
new 25154c3 adding jboss repository (for drools dependencies)
new 793fe22 trivial improvement in error handling
new 85a3ca6 SLING-1803 - adding emma report. runs with -P emma
new 3106d97 SLING-1843 - adding launchpad:display-bundle-updates goal
new c31bbfa Update to recent snapshots
new bad22bd prepping maven-launchpad-plugin for release
new 63eaf6e [maven-release-plugin] prepare release maven-launchpad-plugin-2.0.8
new 9fd2bdb [maven-release-plugin] prepare for next development iteration
new 61f3f68 SLING-1597 - adding config installation via launchpad
new c0518da removing LICENSE and NOTICE files for future releases
new ede6563 SLING-1980 - fixing by adding some code as described by Benjamin on maven-users
new f33d169 updating pom pre-release
new 64e03a1 [maven-release-plugin] prepare release maven-launchpad-plugin-2.0.10
new 6cec043 [maven-release-plugin] prepare for next development iteration
new c80a1cc using snapshots during vote
new d8dc15d Temporarily upgrade to 1.0.1-SNAPSHOT of the launchpad API to not fail builds
new 8c84089 SLING-1988 - removing errant files
new 2cddbb6 removing empty dir
new b751260 SLING-2105 - initial implementation of partial bundle lists
new f23f3d6 Code cleanup - remove unused stuff.
new d8c44e2 Code cleanup - remove unused stuff.
new 67eb316 SLING-2124 : Improve support for OSGi installer by distinguishing between bootstrap and app bundles
new 79e6e41 SLING-2124 : Improve support for OSGi installer by distinguishing between bootstrap and app bundles
new 2d6b5a8 SLING-2124 : Improve support for OSGi installer by distinguishing between bootstrap and app bundles
new cb3b66f SLING-2124 : Improve support for OSGi installer by distinguishing between bootstrap and app bundles
new 0a616ce SLING-2124 : Improve support for OSGi installer by distinguishing between bootstrap and app bundles
new 2fc71ae Remove unused code
new d72004a SLING-2134 : Provide a way to add additional properties to sling.properties
new 5039e0f SLING-2135 : Copying of resources should respect default includes
new 13dad4c SLING-2134 : Provide a way to add additional properties to sling.properties
new 98a09a7 SLING-2150 : Update plugins to use the latest available versions
new a0121dc Update to recent snapshot
new 893c07a Update to recent snapshot
new 917e094 Using latest released parent pom
new ba156ae SLING-2182 : Provide a way to specify additional bootstrap commands
new 934711b SLING-2182 : Provide a way to specify additional bootstrap commands
new 97dac9a SLING-2183 : Bundle configurations and sling files with bundlelist
new 0f6d05c Using released versions
new dff0438 SLING-2134 : Provide a way to add additional properties to sling.properties SLING-2182 : Provide a way to specify additional bootstrap commands
new f1a9178 SLING-2182 : Provide a way to specify additional bootstrap commands
new a35a90d SLING-2187 - adding new module to contain our custom notice file; adding remote-resources plugin configuration to parent pom and removing all existing appended-resources NOTICE files
new 179cc9b temporarily using snapshots during release vote
new 02a8aea SLING-2207 : Support different properties and bootstrap commands for standalone and webapp
new 44145b7 SLING-2207 : Support different properties and bootstrap commands for standalone and webapp
new 3b2fc20 Prepare for release
new 3325362 [maven-release-plugin] prepare release maven-launchpad-plugin-2.1.0
new f02592e [maven-release-plugin] prepare for next development iteration
new 4b57990 Use latest snapshot after release
new d32ced5 using latest releases
new 1a827c3 SLING-2212 : When merging bundle lists, the highest version should win
new bc03898 SLING-2238 - doing property interpolation on bundle list
new 6a0e12a SLING-2241 - AbstractLaunchpadStartingMojo uses protected fields from parent class
new b497a89 SLING-2194 - generating bundle list content from a project's dependencies; refactoring testing projects to use this feature.
new c2c4f2f SLING-2263 - validating partial bundle lists during their lifecycle
new 52fb200 trivial formatting and field name change
new eb65f0b SLING-2264 - add option to set includeDefaultBundles on command line
new 69e8764 SLING-2265 - adding maven-dependency-plugin style option includeDepenencies
new e0008c4 SLING-2273 - implementing a LifecycleParticipant which adds bundle list contents as dependencies
new 5d54df5 SLING-2292 - dependencies added by LaunchpadPluginLifecycleParticipant should be of scope provided
new c3a7120 SLING-2310 : Attach bundle list goal should also add configuration artifact
new 52f90be SLING-2203 : Allow for better configuration of sling home folder
new 5deee11 SLING-2331 : Values in partial bundle list should be interpolated Maven style
new bce914d SLING-2332 : Partial bundle list should be attachable to any maven project
new 210d0d4 SLING-2194 : generate a partial bundle list from a project's dependencies SLING-2265 : maven-launchpad-plugin should support a syntax similar to the maven-dependency-plugin
new 92b1ba9 SLING-2263 - no longer need to validate bundle lists as SLING-2273 handles that now.
new 802751b removing unused code
new bb6cf72 SLING-2194 - fail the build if a bundle list isn't available as this is now the only way to define a partial bundle list.
new 023486f SLING-2386 : It should be possible to remove bundles from an inherited partial bundle list. Apply patch from Timo Naroska
new 5099e0e SLING-2434 - upgrding to Drools 2.3.1.Final as that's in Maven Central
new 29f1677 SLING-2480 : Add config for maven-sling-plugin to m2e configuration
new 54d5e7f Update to latest parent pom
new d3b3dde Use released versions
new 2165db9 Use released version instead of older snapshot
new 069d580 [maven-release-plugin] prepare release maven-launchpad-plugin-2.1.2
new 2f1d9ed [maven-release-plugin] prepare for next development iteration
new bf9822b SLING-2589 : Project Configurations are overwritten by inherited
new 2bdd3ee SLING-2590 : Provide a way to exclude configurations from partial bundle lists
new 8285db3 SLING-2591 : Provide a way to exclude sling properties from partial bundle lists
new 42036ef SLING-2620 - creating target directories if they don't exist already
new 1bbcc8a SLING.2649 : Add support for run modes
new 064f394 SLING-2649 : Add support for run modes
new a428611 SLING-2662 : Enhance run mode handling
new 60ffbf5 [maven-release-plugin] prepare release maven-launchpad-plugin-2.2.0
new 5c61ac0 [maven-release-plugin] copy for tag maven-launchpad-plugin-2.2.0
The 119 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
--
To stop receiving notification emails like this one, please contact
['"commits@sling.apache.org" <co...@sling.apache.org>'].
[sling-maven-launchpad-plugin] 07/10: SLING-2649 : Add support for
run modes
Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
rombert pushed a commit to annotated tag maven-launchpad-plugin-2.2.0
in repository https://gitbox.apache.org/repos/asf/sling-maven-launchpad-plugin.git
commit 064f39482e11322b450537aa90027978afab00e8
Author: Carsten Ziegeler <cz...@apache.org>
AuthorDate: Wed Nov 14 11:35:29 2012 +0000
SLING-2649 : Add support for run modes
git-svn-id: https://svn.apache.org/repos/asf/sling/trunk/maven/maven-launchpad-plugin@1409168 13f79535-47bb-0310-9956-ffa450edef68
---
.../sling/maven/projectsupport/AbstractLaunchpadStartingMojo.java | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/src/main/java/org/apache/sling/maven/projectsupport/AbstractLaunchpadStartingMojo.java b/src/main/java/org/apache/sling/maven/projectsupport/AbstractLaunchpadStartingMojo.java
index 867535e..bb27287 100644
--- a/src/main/java/org/apache/sling/maven/projectsupport/AbstractLaunchpadStartingMojo.java
+++ b/src/main/java/org/apache/sling/maven/projectsupport/AbstractLaunchpadStartingMojo.java
@@ -166,6 +166,12 @@ public abstract class AbstractLaunchpadStartingMojo extends AbstractUsingBundleL
} catch (NumberFormatException e) {
// we ignore this
}
+ } else if (path.equals("resources") ) {
+ final Set<String> subDirs = new HashSet<String>();
+ subDirs.add(BUNDLE_PATH_PREFIX);
+ subDirs.add(CONFIG_PATH_PREFIX);
+ subDirs.add("resources/corebundles");
+ return subDirs.iterator();
}
getLog().warn("un-handlable path " + path);
@@ -328,6 +334,7 @@ public abstract class AbstractLaunchpadStartingMojo extends AbstractUsingBundleL
}
}
+ @Override
protected void initArtifactDefinitions(Properties dependencies) {
if (jarWebSupport == null) {
jarWebSupport = new ArtifactDefinition();
--
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.
[sling-maven-launchpad-plugin] 10/10: [maven-release-plugin] copy
for tag maven-launchpad-plugin-2.2.0
Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
rombert pushed a commit to annotated tag maven-launchpad-plugin-2.2.0
in repository https://gitbox.apache.org/repos/asf/sling-maven-launchpad-plugin.git
commit 5c61ac035c2a1487fae73a02e746b874ef63ba19
Author: Carsten Ziegeler <cz...@apache.org>
AuthorDate: Fri Nov 16 07:50:24 2012 +0000
[maven-release-plugin] copy for tag maven-launchpad-plugin-2.2.0
git-svn-id: https://svn.apache.org/repos/asf/sling/tags/maven-launchpad-plugin-2.2.0@1410233 13f79535-47bb-0310-9956-ffa450edef68
--
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.
[sling-maven-launchpad-plugin] 04/10: SLING-2591 : Provide a way to
exclude sling properties from partial bundle lists
Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
rombert pushed a commit to annotated tag maven-launchpad-plugin-2.2.0
in repository https://gitbox.apache.org/repos/asf/sling-maven-launchpad-plugin.git
commit 8285db3efc5de3e6f374f8a7b1e3c3eea67295ef
Author: Carsten Ziegeler <cz...@apache.org>
AuthorDate: Thu Aug 30 15:33:26 2012 +0000
SLING-2591 : Provide a way to exclude sling properties from partial bundle lists
git-svn-id: https://svn.apache.org/repos/asf/sling/trunk/maven/maven-launchpad-plugin@1378990 13f79535-47bb-0310-9956-ffa450edef68
---
.../AbstractUsingBundleListMojo.java | 26 ++++++++++++++++++++--
1 file changed, 24 insertions(+), 2 deletions(-)
diff --git a/src/main/java/org/apache/sling/maven/projectsupport/AbstractUsingBundleListMojo.java b/src/main/java/org/apache/sling/maven/projectsupport/AbstractUsingBundleListMojo.java
index ce579ed..5640cba 100644
--- a/src/main/java/org/apache/sling/maven/projectsupport/AbstractUsingBundleListMojo.java
+++ b/src/main/java/org/apache/sling/maven/projectsupport/AbstractUsingBundleListMojo.java
@@ -108,7 +108,7 @@ public abstract class AbstractUsingBundleListMojo extends AbstractBundleListMojo
private File[] rewriteRuleFiles;
/**
- * The comma separated list of tokens to include when copying configs
+ * The list of tokens to include when copying configs
* from partial bundle lists.
*
* @parameter default-value="**"
@@ -116,7 +116,7 @@ public abstract class AbstractUsingBundleListMojo extends AbstractBundleListMojo
private String[] configIncludes;
/**
- * The comma separated list of tokens to exclude when copying the configs
+ * The list of tokens to exclude when copying the configs
* from partial bundle lists.
*
* @parameter
@@ -124,6 +124,14 @@ public abstract class AbstractUsingBundleListMojo extends AbstractBundleListMojo
private String[] configExcludes;
/**
+ * The list of names to exclude when copying properties
+ * from partial bundle lists.
+ *
+ * @parameter
+ */
+ private String[] propertiesExcludes;
+
+ /**
* @component
*/
protected MavenFileFilter mavenFileFilter;
@@ -406,18 +414,21 @@ public abstract class AbstractUsingBundleListMojo extends AbstractBundleListMojo
} else {
this.copyProperties(loadedProps, this.slingProperties);
}
+ filterProperties(this.slingProperties);
} else if ( mode == 1 ) {
if ( this.slingWebappProperties == null ) {
this.slingWebappProperties = loadedProps;
} else {
this.copyProperties(loadedProps, this.slingWebappProperties);
}
+ filterProperties(this.slingWebappProperties);
} else {
if ( this.slingStandaloneProperties == null ) {
this.slingStandaloneProperties = loadedProps;
} else {
this.copyProperties(loadedProps, this.slingStandaloneProperties);
}
+ filterProperties(this.slingStandaloneProperties);
}
} catch (IOException e) {
throw new MojoExecutionException("Unable to create filtered properties file", e);
@@ -431,6 +442,17 @@ public abstract class AbstractUsingBundleListMojo extends AbstractBundleListMojo
}
}
+ /**
+ * Filter properties by removing excluded properties
+ */
+ private void filterProperties(final Properties props) {
+ if ( this.propertiesExcludes != null ) {
+ for(final String name : this.propertiesExcludes) {
+ props.remove(name.trim());
+ }
+ }
+ }
+
protected Properties getSlingProperties(final boolean standalone) throws MojoExecutionException {
readSlingProperties(this.commonSlingProps, 0);
final Properties additionalProps = (standalone ? this.slingStandaloneProperties : this.slingWebappProperties);
--
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.
[sling-maven-launchpad-plugin] 09/10: [maven-release-plugin]
prepare release maven-launchpad-plugin-2.2.0
Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
rombert pushed a commit to annotated tag maven-launchpad-plugin-2.2.0
in repository https://gitbox.apache.org/repos/asf/sling-maven-launchpad-plugin.git
commit 60ffbf5a123da1bdcedc81a650da2c6e7a8cfa3b
Author: Carsten Ziegeler <cz...@apache.org>
AuthorDate: Fri Nov 16 07:50:11 2012 +0000
[maven-release-plugin] prepare release maven-launchpad-plugin-2.2.0
git-svn-id: https://svn.apache.org/repos/asf/sling/trunk/maven/maven-launchpad-plugin@1410232 13f79535-47bb-0310-9956-ffa450edef68
---
pom.xml | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/pom.xml b/pom.xml
index f0e0ff9..c0ba955 100644
--- a/pom.xml
+++ b/pom.xml
@@ -22,7 +22,7 @@
</parent>
<artifactId>maven-launchpad-plugin</artifactId>
- <version>2.1.3-SNAPSHOT</version>
+ <version>2.2.0</version>
<packaging>maven-plugin</packaging>
<name>Apache Sling Launchpad Maven Plugin</name>
@@ -31,9 +31,9 @@
</description>
<scm>
- <connection>scm:svn:http://svn.apache.org/repos/asf/sling/trunk/maven/maven-launchpad-plugin</connection>
- <developerConnection>scm:svn:https://svn.apache.org/repos/asf/sling/trunk/maven/maven-launchpad-plugin</developerConnection>
- <url>http://svn.apache.org/viewvc/sling/trunk/maven/maven-launchpad-plugin</url>
+ <connection>scm:svn:http://svn.apache.org/repos/asf/sling/tags/maven-launchpad-plugin-2.2.0</connection>
+ <developerConnection>scm:svn:https://svn.apache.org/repos/asf/sling/tags/maven-launchpad-plugin-2.2.0</developerConnection>
+ <url>http://svn.apache.org/viewvc/sling/tags/maven-launchpad-plugin-2.2.0</url>
</scm>
<build>
--
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.
[sling-maven-launchpad-plugin] 01/10: [maven-release-plugin]
prepare for next development iteration
Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
rombert pushed a commit to annotated tag maven-launchpad-plugin-2.2.0
in repository https://gitbox.apache.org/repos/asf/sling-maven-launchpad-plugin.git
commit 2f1d9ed34c6d0649e18f4f15f0eea4a09d1b59a2
Author: Carsten Ziegeler <cz...@apache.org>
AuthorDate: Wed Aug 15 13:17:56 2012 +0000
[maven-release-plugin] prepare for next development iteration
git-svn-id: https://svn.apache.org/repos/asf/sling/trunk/maven/maven-launchpad-plugin@1373390 13f79535-47bb-0310-9956-ffa450edef68
---
pom.xml | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/pom.xml b/pom.xml
index c5ac9bc..04a33dd 100644
--- a/pom.xml
+++ b/pom.xml
@@ -22,7 +22,7 @@
</parent>
<artifactId>maven-launchpad-plugin</artifactId>
- <version>2.1.2</version>
+ <version>2.1.3-SNAPSHOT</version>
<packaging>maven-plugin</packaging>
<name>Apache Sling Launchpad Maven Plugin</name>
@@ -31,9 +31,9 @@
</description>
<scm>
- <connection>scm:svn:http://svn.apache.org/repos/asf/sling/tags/maven-launchpad-plugin-2.1.2</connection>
- <developerConnection>scm:svn:https://svn.apache.org/repos/asf/sling/tags/maven-launchpad-plugin-2.1.2</developerConnection>
- <url>http://svn.apache.org/viewvc/sling/tags/maven-launchpad-plugin-2.1.2</url>
+ <connection>scm:svn:http://svn.apache.org/repos/asf/sling/trunk/maven/maven-launchpad-plugin</connection>
+ <developerConnection>scm:svn:https://svn.apache.org/repos/asf/sling/trunk/maven/maven-launchpad-plugin</developerConnection>
+ <url>http://svn.apache.org/viewvc/sling/trunk/maven/maven-launchpad-plugin</url>
</scm>
<build>
--
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.
[sling-maven-launchpad-plugin] 05/10: SLING-2620 - creating target
directories if they don't exist already
Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
rombert pushed a commit to annotated tag maven-launchpad-plugin-2.2.0
in repository https://gitbox.apache.org/repos/asf/sling-maven-launchpad-plugin.git
commit 42036ef0d43dc957b2640437cda67adc64eb2c2f
Author: Justin Edelson <ju...@apache.org>
AuthorDate: Tue Oct 16 20:40:40 2012 +0000
SLING-2620 - creating target directories if they don't exist already
git-svn-id: https://svn.apache.org/repos/asf/sling/trunk/maven/maven-launchpad-plugin@1398986 13f79535-47bb-0310-9956-ffa450edef68
---
.../java/org/apache/sling/maven/projectsupport/AttachBundleListMojo.java | 1 +
.../apache/sling/maven/projectsupport/AttachPartialBundleListMojo.java | 1 +
2 files changed, 2 insertions(+)
diff --git a/src/main/java/org/apache/sling/maven/projectsupport/AttachBundleListMojo.java b/src/main/java/org/apache/sling/maven/projectsupport/AttachBundleListMojo.java
index a64d84f..6f40dc0 100644
--- a/src/main/java/org/apache/sling/maven/projectsupport/AttachBundleListMojo.java
+++ b/src/main/java/org/apache/sling/maven/projectsupport/AttachBundleListMojo.java
@@ -61,6 +61,7 @@ public class AttachBundleListMojo extends AbstractUsingBundleListMojo {
protected void executeWithArtifacts() throws MojoExecutionException, MojoFailureException {
FileWriter fw = null;
try {
+ this.outputFile.getParentFile().mkdirs();
fw = new FileWriter(outputFile);
writer.write(fw, getInitializedBundleList());
projectHelper.attachArtifact(project, AttachPartialBundleListMojo.TYPE, AttachPartialBundleListMojo.CLASSIFIER, outputFile);
diff --git a/src/main/java/org/apache/sling/maven/projectsupport/AttachPartialBundleListMojo.java b/src/main/java/org/apache/sling/maven/projectsupport/AttachPartialBundleListMojo.java
index c157a80..f909a35 100644
--- a/src/main/java/org/apache/sling/maven/projectsupport/AttachPartialBundleListMojo.java
+++ b/src/main/java/org/apache/sling/maven/projectsupport/AttachPartialBundleListMojo.java
@@ -97,6 +97,7 @@ public class AttachPartialBundleListMojo extends AbstractBundleListMojo {
final BundleListXpp3Writer writer = new BundleListXpp3Writer();
try {
+ this.bundleListOutput.getParentFile().mkdirs();
writer.write(new FileWriter(bundleListOutput), initializedBundleList);
} catch (IOException e) {
throw new MojoExecutionException("Unable to write bundle list", e);
--
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.
[sling-maven-launchpad-plugin] 03/10: SLING-2590 : Provide a way to
exclude configurations from partial bundle lists
Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
rombert pushed a commit to annotated tag maven-launchpad-plugin-2.2.0
in repository https://gitbox.apache.org/repos/asf/sling-maven-launchpad-plugin.git
commit 2bdd3eee778256421f1c2b0270f7cc10d8fe7775
Author: Carsten Ziegeler <cz...@apache.org>
AuthorDate: Thu Aug 30 15:14:33 2012 +0000
SLING-2590 : Provide a way to exclude configurations from partial bundle lists
git-svn-id: https://svn.apache.org/repos/asf/sling/trunk/maven/maven-launchpad-plugin@1378983 13f79535-47bb-0310-9956-ffa450edef68
---
.../AbstractUsingBundleListMojo.java | 27 +++++++++++++++++++++-
1 file changed, 26 insertions(+), 1 deletion(-)
diff --git a/src/main/java/org/apache/sling/maven/projectsupport/AbstractUsingBundleListMojo.java b/src/main/java/org/apache/sling/maven/projectsupport/AbstractUsingBundleListMojo.java
index 34a8b02..ce579ed 100644
--- a/src/main/java/org/apache/sling/maven/projectsupport/AbstractUsingBundleListMojo.java
+++ b/src/main/java/org/apache/sling/maven/projectsupport/AbstractUsingBundleListMojo.java
@@ -38,6 +38,7 @@ import org.apache.sling.maven.projectsupport.bundlelist.v1_0_0.BundleList;
import org.codehaus.plexus.archiver.ArchiverException;
import org.codehaus.plexus.archiver.zip.ZipUnArchiver;
import org.codehaus.plexus.util.FileUtils;
+import org.codehaus.plexus.util.StringUtils;
import org.codehaus.plexus.util.xml.pull.XmlPullParserException;
import org.drools.KnowledgeBase;
import org.drools.KnowledgeBaseFactory;
@@ -107,6 +108,22 @@ public abstract class AbstractUsingBundleListMojo extends AbstractBundleListMojo
private File[] rewriteRuleFiles;
/**
+ * The comma separated list of tokens to include when copying configs
+ * from partial bundle lists.
+ *
+ * @parameter default-value="**"
+ */
+ private String[] configIncludes;
+
+ /**
+ * The comma separated list of tokens to exclude when copying the configs
+ * from partial bundle lists.
+ *
+ * @parameter
+ */
+ private String[] configExcludes;
+
+ /**
* @component
*/
protected MavenFileFilter mavenFileFilter;
@@ -312,8 +329,16 @@ public abstract class AbstractUsingBundleListMojo extends AbstractBundleListMojo
this.tempConfigDir.mkdirs();
this.overlayConfigDir = this.tempConfigDir;
}
+ String excludes = FileUtils.getDefaultExcludesAsString();
+ if ( this.configExcludes != null ) {
+ excludes = excludes + ',' + StringUtils.join(this.configExcludes, ",");
+ }
+ String includes = null;
+ if ( this.configIncludes != null ) {
+ includes = StringUtils.join(this.configIncludes, ",");
+ }
FileUtils.copyDirectory(configDir, this.overlayConfigDir,
- null, FileUtils.getDefaultExcludesAsString());
+ includes, excludes);
}
} catch (final ArchiverException ae) {
throw new MojoExecutionException("Unable to extract configuration archive.",ae);
--
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.
[sling-maven-launchpad-plugin] 08/10: SLING-2662 : Enhance run mode
handling
Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
rombert pushed a commit to annotated tag maven-launchpad-plugin-2.2.0
in repository https://gitbox.apache.org/repos/asf/sling-maven-launchpad-plugin.git
commit a428611bd8f3b382871f1b62e4d6de6382f10677
Author: Carsten Ziegeler <cz...@apache.org>
AuthorDate: Thu Nov 15 08:04:01 2012 +0000
SLING-2662 : Enhance run mode handling
git-svn-id: https://svn.apache.org/repos/asf/sling/trunk/maven/maven-launchpad-plugin@1409683 13f79535-47bb-0310-9956-ffa450edef68
---
pom.xml | 5 +++
.../projectsupport/AbstractBundleListMojo.java | 37 ++++++++++++++++++++++
.../AbstractUsingBundleListMojo.java | 19 ++++++-----
.../maven/projectsupport/AttachBundleListMojo.java | 4 +--
.../AttachPartialBundleListMojo.java | 4 +--
.../maven/projectsupport/PreparePackageMojo.java | 6 ++--
6 files changed, 61 insertions(+), 14 deletions(-)
diff --git a/pom.xml b/pom.xml
index 04a33dd..f0e0ff9 100644
--- a/pom.xml
+++ b/pom.xml
@@ -148,6 +148,11 @@
<version>1.5.15</version>
</dependency>
<dependency>
+ <groupId>commons-io</groupId>
+ <artifactId>commons-io</artifactId>
+ <version>2.4</version>
+ </dependency>
+ <dependency>
<groupId>org.jdom</groupId>
<artifactId>jdom</artifactId>
<version>1.1</version>
diff --git a/src/main/java/org/apache/sling/maven/projectsupport/AbstractBundleListMojo.java b/src/main/java/org/apache/sling/maven/projectsupport/AbstractBundleListMojo.java
index eca43fe..a2f5566 100644
--- a/src/main/java/org/apache/sling/maven/projectsupport/AbstractBundleListMojo.java
+++ b/src/main/java/org/apache/sling/maven/projectsupport/AbstractBundleListMojo.java
@@ -17,6 +17,8 @@
package org.apache.sling.maven.projectsupport;
import java.io.File;
+import java.io.FileFilter;
+import java.io.IOException;
import java.util.List;
import org.apache.maven.artifact.Artifact;
@@ -35,6 +37,7 @@ import org.apache.maven.plugin.AbstractMojo;
import org.apache.maven.plugin.MojoExecutionException;
import org.apache.maven.project.MavenProject;
import org.apache.maven.project.MavenProjectHelper;
+import org.codehaus.plexus.util.SelectorUtils;
import org.codehaus.plexus.util.StringUtils;
public abstract class AbstractBundleListMojo extends AbstractMojo {
@@ -219,4 +222,38 @@ public abstract class AbstractBundleListMojo extends AbstractMojo {
return artifact;
}
+ /**
+ * Helper method to copy a whole directory
+ */
+ protected void copyDirectory(final File source, final File target, final String[] includes, final String[] excludes)
+ throws IOException {
+ final String prefix = source.getAbsolutePath() + File.separatorChar;
+ final int prefixLength = prefix.length();
+ org.apache.commons.io.FileUtils.copyDirectory(source, target, new FileFilter() {
+
+ public boolean accept(final File file) {
+ final String path = file.getAbsolutePath().substring(prefixLength).replace(File.separatorChar, '/');
+ if ( includes != null ) {
+ boolean matched = false;
+ for(int i = 0; i<includes.length && !matched; i++) {
+ if ( SelectorUtils.matchPath(includes[i], path)) {
+ matched = true;
+ }
+ }
+ if ( !matched ) {
+ return false;
+ }
+ }
+ if ( excludes != null ) {
+ for(final String pattern:excludes) {
+ if ( SelectorUtils.matchPath(pattern, path)) {
+ return false;
+ }
+ }
+ }
+ return true;
+ }
+ });
+ }
+
}
diff --git a/src/main/java/org/apache/sling/maven/projectsupport/AbstractUsingBundleListMojo.java b/src/main/java/org/apache/sling/maven/projectsupport/AbstractUsingBundleListMojo.java
index 5640cba..41e45a4 100644
--- a/src/main/java/org/apache/sling/maven/projectsupport/AbstractUsingBundleListMojo.java
+++ b/src/main/java/org/apache/sling/maven/projectsupport/AbstractUsingBundleListMojo.java
@@ -38,7 +38,6 @@ import org.apache.sling.maven.projectsupport.bundlelist.v1_0_0.BundleList;
import org.codehaus.plexus.archiver.ArchiverException;
import org.codehaus.plexus.archiver.zip.ZipUnArchiver;
import org.codehaus.plexus.util.FileUtils;
-import org.codehaus.plexus.util.StringUtils;
import org.codehaus.plexus.util.xml.pull.XmlPullParserException;
import org.drools.KnowledgeBase;
import org.drools.KnowledgeBaseFactory;
@@ -293,8 +292,7 @@ public abstract class AbstractUsingBundleListMojo extends AbstractBundleListMojo
}
// copy own config files
if ( this.overlayConfigDir != null && super.getConfigDirectory().exists() ) {
- FileUtils.copyDirectory(super.getConfigDirectory(), this.overlayConfigDir,
- null, FileUtils.getDefaultExcludesAsString());
+ copyDirectory(super.getConfigDirectory(), this.overlayConfigDir, null, FileUtils.getDefaultExcludes());
}
}
@@ -337,15 +335,20 @@ public abstract class AbstractUsingBundleListMojo extends AbstractBundleListMojo
this.tempConfigDir.mkdirs();
this.overlayConfigDir = this.tempConfigDir;
}
- String excludes = FileUtils.getDefaultExcludesAsString();
+ final String[] defaultExcludes = FileUtils.getDefaultExcludes();
+ String[] excludes;
if ( this.configExcludes != null ) {
- excludes = excludes + ',' + StringUtils.join(this.configExcludes, ",");
+ excludes = new String[defaultExcludes.length + this.configExcludes.length];
+ System.arraycopy(defaultExcludes, 0, excludes, 0, defaultExcludes.length);
+ System.arraycopy(this.configExcludes, 0, excludes, defaultExcludes.length, this.configExcludes.length);
+ } else {
+ excludes = defaultExcludes;
}
- String includes = null;
+ String[] includes = null;
if ( this.configIncludes != null ) {
- includes = StringUtils.join(this.configIncludes, ",");
+ includes = this.configIncludes;
}
- FileUtils.copyDirectory(configDir, this.overlayConfigDir,
+ copyDirectory(configDir, this.overlayConfigDir,
includes, excludes);
}
} catch (final ArchiverException ae) {
diff --git a/src/main/java/org/apache/sling/maven/projectsupport/AttachBundleListMojo.java b/src/main/java/org/apache/sling/maven/projectsupport/AttachBundleListMojo.java
index 6f40dc0..fe9d538 100644
--- a/src/main/java/org/apache/sling/maven/projectsupport/AttachBundleListMojo.java
+++ b/src/main/java/org/apache/sling/maven/projectsupport/AttachBundleListMojo.java
@@ -142,8 +142,8 @@ public class AttachBundleListMojo extends AbstractUsingBundleListMojo {
if ( this.checkFile(this.getConfigDirectory()) ) {
final File configDir = new File(this.configOutputDir, "config");
configDir.mkdirs();
- FileUtils.copyDirectory(this.getConfigDirectory(), configDir,
- null, FileUtils.getDefaultExcludesAsString());
+ copyDirectory(this.getConfigDirectory(), configDir,
+ null, FileUtils.getDefaultExcludes());
}
final File destFile = new File(this.configOutputDir.getParent(), this.configOutputDir.getName() + ".zip");
zipArchiver.setDestFile(destFile);
diff --git a/src/main/java/org/apache/sling/maven/projectsupport/AttachPartialBundleListMojo.java b/src/main/java/org/apache/sling/maven/projectsupport/AttachPartialBundleListMojo.java
index f909a35..2f4caf5 100644
--- a/src/main/java/org/apache/sling/maven/projectsupport/AttachPartialBundleListMojo.java
+++ b/src/main/java/org/apache/sling/maven/projectsupport/AttachPartialBundleListMojo.java
@@ -178,8 +178,8 @@ public class AttachPartialBundleListMojo extends AbstractBundleListMojo {
if ( this.checkFile(this.getConfigDirectory()) ) {
final File configDir = new File(this.configOutputDir, "config");
configDir.mkdirs();
- FileUtils.copyDirectory(this.getConfigDirectory(), configDir,
- null, FileUtils.getDefaultExcludesAsString());
+ copyDirectory(this.getConfigDirectory(), configDir,
+ null, FileUtils.getDefaultExcludes());
}
final File destFile = new File(this.configOutputDir.getParent(), this.configOutputDir.getName() + ".zip");
zipArchiver.setDestFile(destFile);
diff --git a/src/main/java/org/apache/sling/maven/projectsupport/PreparePackageMojo.java b/src/main/java/org/apache/sling/maven/projectsupport/PreparePackageMojo.java
index 378857c..5a541cd 100644
--- a/src/main/java/org/apache/sling/maven/projectsupport/PreparePackageMojo.java
+++ b/src/main/java/org/apache/sling/maven/projectsupport/PreparePackageMojo.java
@@ -107,6 +107,7 @@ public class PreparePackageMojo extends AbstractLaunchpadFrameworkMojo {
*/
private JarArchiver jarArchiver;
+ @Override
public void executeWithArtifacts() throws MojoExecutionException, MojoFailureException {
copyBaseArtifact();
copyBundles(getInitializedBundleList(), getOutputDirectory());
@@ -116,6 +117,7 @@ public class PreparePackageMojo extends AbstractLaunchpadFrameworkMojo {
}
}
+ @Override
protected void initArtifactDefinitions(Properties dependencies) {
if (base == null) {
base = new ArtifactDefinition();
@@ -278,7 +280,7 @@ public class PreparePackageMojo extends AbstractLaunchpadFrameworkMojo {
}
private Artifact getBaseDependency() {
- return (Artifact) project.getArtifactMap().get(
+ return project.getArtifactMap().get(
base.getGroupId() + ":" + base.getArtifactId());
}
@@ -303,7 +305,7 @@ public class PreparePackageMojo extends AbstractLaunchpadFrameworkMojo {
private void copyConfigurationFiles() throws MojoExecutionException {
try {
- FileUtils.copyDirectory(this.getConfigDirectory(), new File(getOutputDirectory(), CONFIG_PATH_PREFIX), null, FileUtils.getDefaultExcludesAsString());
+ copyDirectory(this.getConfigDirectory(), new File(getOutputDirectory(), CONFIG_PATH_PREFIX), null, FileUtils.getDefaultExcludes());
} catch (IOException e) {
throw new MojoExecutionException("Unable to copy configuration files", e);
}
--
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.
[sling-maven-launchpad-plugin] 06/10: SLING.2649 : Add support for
run modes
Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
rombert pushed a commit to annotated tag maven-launchpad-plugin-2.2.0
in repository https://gitbox.apache.org/repos/asf/sling-maven-launchpad-plugin.git
commit 1bbcc8a18bcdfefc91939c8567eb824a6eefc9e7
Author: Carsten Ziegeler <cz...@apache.org>
AuthorDate: Tue Nov 13 16:46:14 2012 +0000
SLING.2649 : Add support for run modes
git-svn-id: https://svn.apache.org/repos/asf/sling/trunk/maven/maven-launchpad-plugin@1408828 13f79535-47bb-0310-9956-ffa450edef68
---
.../AbstractLaunchpadFrameworkMojo.java | 39 +++++++++++++++++-----
.../maven/projectsupport/ArtifactDefinition.java | 20 ++++++++---
.../maven/projectsupport/CreateBundleJarMojo.java | 6 ++--
.../projectsupport/PrepareTestWebAppMojo.java | 3 +-
src/main/mdo/bundle-list.xml | 5 +++
5 files changed, 56 insertions(+), 17 deletions(-)
diff --git a/src/main/java/org/apache/sling/maven/projectsupport/AbstractLaunchpadFrameworkMojo.java b/src/main/java/org/apache/sling/maven/projectsupport/AbstractLaunchpadFrameworkMojo.java
index 401f69d..23d16d0 100644
--- a/src/main/java/org/apache/sling/maven/projectsupport/AbstractLaunchpadFrameworkMojo.java
+++ b/src/main/java/org/apache/sling/maven/projectsupport/AbstractLaunchpadFrameworkMojo.java
@@ -18,6 +18,8 @@ package org.apache.sling.maven.projectsupport;
import java.io.File;
import java.io.IOException;
+import java.util.Set;
+import java.util.TreeSet;
import org.apache.maven.artifact.Artifact;
import org.apache.maven.plugin.MojoExecutionException;
@@ -48,20 +50,41 @@ public abstract class AbstractLaunchpadFrameworkMojo extends AbstractUsingBundle
private String bundlesDirectory;
/**
- * The directory which contains the bootstraop bundle directories.
+ * The directory which contains the bootstrap bundle directories.
*
* @parameter
*/
private String bootDirectory;
- protected String getPathForArtifact(final int startLevel, final String artifactName) {
+ protected String getPathForArtifact(final int startLevel, final String artifactName, final String runModes) {
+ final Set<String> runModesList = new TreeSet<String>();
+ if (runModes != null ) {
+ for(final String mode : runModes.split(",")) {
+ if ( mode.trim().length() > 0 ) {
+ runModesList.add(mode);
+ }
+ }
+ }
+ final String runModeExt;
+ if ( runModesList.size() == 0 ) {
+ runModeExt = "";
+ } else {
+ final StringBuilder sb = new StringBuilder();
+ for(final String n : runModesList ) {
+ sb.append('.');
+ sb.append(n);
+ }
+ runModeExt = sb.toString();
+ }
if ( startLevel == -1 && bootDirectory != null ) {
- return String.format("%s/%s/1/%s", baseDestination, bootDirectory,
+ return String.format("%s/%s%s/1/%s", baseDestination, bootDirectory,
+ runModeExt,
artifactName);
}
- return String.format("%s/%s/%s/%s", baseDestination, bundlesDirectory,
+ return String.format("%s/%s%s/%s/%s", baseDestination, bundlesDirectory,
+ runModeExt,
(startLevel == -1 ? 1 : startLevel),
- artifactName);
+ artifactName, runModeExt);
}
protected void copyBundles(BundleList bundles, File outputDirectory) throws MojoExecutionException {
@@ -74,11 +97,11 @@ public abstract class AbstractLaunchpadFrameworkMojo extends AbstractUsingBundle
protected void copy(ArtifactDefinition additionalBundle, File outputDirectory) throws MojoExecutionException {
Artifact artifact = getArtifact(additionalBundle);
- copy(artifact.getFile(), additionalBundle.getStartLevel(), outputDirectory);
+ copy(artifact.getFile(), additionalBundle.getStartLevel(), additionalBundle.getRunModes(), outputDirectory);
}
- protected void copy(File file, int startLevel, File outputDirectory) throws MojoExecutionException {
- File destination = new File(outputDirectory, getPathForArtifact(startLevel, file.getName().replace('/', File.separatorChar)));
+ protected void copy(File file, int startLevel, String runModes, File outputDirectory) throws MojoExecutionException {
+ File destination = new File(outputDirectory, getPathForArtifact(startLevel, file.getName().replace('/', File.separatorChar), runModes));
if (shouldCopy(file, destination)) {
getLog().info(String.format("Copying bundle from %s to %s", file.getPath(), destination.getPath()));
try {
diff --git a/src/main/java/org/apache/sling/maven/projectsupport/ArtifactDefinition.java b/src/main/java/org/apache/sling/maven/projectsupport/ArtifactDefinition.java
index edb4271..2183c2e 100644
--- a/src/main/java/org/apache/sling/maven/projectsupport/ArtifactDefinition.java
+++ b/src/main/java/org/apache/sling/maven/projectsupport/ArtifactDefinition.java
@@ -16,7 +16,7 @@
*/
package org.apache.sling.maven.projectsupport;
-import static org.apache.sling.maven.projectsupport.BundleListUtils.*;
+import static org.apache.sling.maven.projectsupport.BundleListUtils.nodeValue;
import org.apache.maven.model.Dependency;
import org.apache.sling.maven.projectsupport.bundlelist.v1_0_0.Bundle;
@@ -46,9 +46,12 @@ public class ArtifactDefinition {
/** The artifact version */
private String version;
+ /** The artifact run modes */
+ private String runModes;
+
public ArtifactDefinition() {
}
-
+
public ArtifactDefinition(Bundle bundle, int startLevel) {
this.groupId = bundle.getGroupId();
this.artifactId = bundle.getArtifactId();
@@ -56,6 +59,7 @@ public class ArtifactDefinition {
this.version = bundle.getVersion();
this.classifier = bundle.getClassifier();
this.startLevel = startLevel;
+ this.runModes = bundle.getRunModes();
}
public ArtifactDefinition(Xpp3Dom config) {
@@ -65,6 +69,7 @@ public class ArtifactDefinition {
this.version = nodeValue(config, "version", null);
this.classifier = nodeValue(config, "classifier", null);
this.startLevel = nodeValue(config, "startLevel", 0);
+ this.runModes = nodeValue(config, "runModes", null);
}
public String getArtifactId() {
@@ -91,6 +96,10 @@ public class ArtifactDefinition {
return version;
}
+ public String getRunModes() {
+ return runModes;
+ }
+
public void setArtifactId(String artifactId) {
this.artifactId = artifactId;
}
@@ -119,7 +128,8 @@ public class ArtifactDefinition {
public String toString() {
return "ArtifactDefinition [artifactId=" + artifactId + ", classifier="
+ classifier + ", groupId=" + groupId + ", startLevel="
- + startLevel + ", type=" + type + ", version=" + version + "]";
+ + startLevel + ", type=" + type + ", version=" + version
+ + ", runModes=" + runModes + "]";
}
/**
@@ -198,7 +208,7 @@ public class ArtifactDefinition {
bnd.setStartLevel(startLevel);
return bnd;
}
-
+
public Dependency toDependency(String scope) {
Dependency dep = new Dependency();
dep.setArtifactId(artifactId);
@@ -211,7 +221,7 @@ public class ArtifactDefinition {
dep.setScope(scope);
return dep;
}
-
+
public static Dependency toDependency(Bundle bundle, String scope) {
return new ArtifactDefinition(bundle, 0).toDependency(scope);
}
diff --git a/src/main/java/org/apache/sling/maven/projectsupport/CreateBundleJarMojo.java b/src/main/java/org/apache/sling/maven/projectsupport/CreateBundleJarMojo.java
index dc848e7..c46da9b 100644
--- a/src/main/java/org/apache/sling/maven/projectsupport/CreateBundleJarMojo.java
+++ b/src/main/java/org/apache/sling/maven/projectsupport/CreateBundleJarMojo.java
@@ -81,7 +81,7 @@ public class CreateBundleJarMojo extends AbstractLaunchpadFrameworkMojo {
for (Bundle bundle : level.getBundles()) {
Artifact artifact = getArtifact(new ArtifactDefinition(bundle,
level.getStartLevel()));
- final String destFileName = getPathForArtifact(level.getStartLevel(), artifact.getFile().getName());
+ final String destFileName = getPathForArtifact(level.getStartLevel(), bundle.getRunModes(), artifact.getFile().getName());
try {
jarArchiver.addFile(artifact.getFile(), destFileName);
} catch (ArchiverException e) {
@@ -168,13 +168,13 @@ public class CreateBundleJarMojo extends AbstractLaunchpadFrameworkMojo {
DirectoryScanner scanner = new DirectoryScanner();
scanner.setBasedir(resource.getDirectory());
if (resource.getIncludes() != null && !resource.getIncludes().isEmpty()) {
- scanner.setIncludes((String[]) resource.getIncludes().toArray(
+ scanner.setIncludes(resource.getIncludes().toArray(
new String[resource.getIncludes().size()]));
} else {
scanner.setIncludes(DEFAULT_INCLUDES);
}
if (resource.getExcludes() != null && !resource.getExcludes().isEmpty()) {
- scanner.setExcludes((String[]) resource.getExcludes().toArray(
+ scanner.setExcludes(resource.getExcludes().toArray(
new String[resource.getExcludes().size()]));
}
diff --git a/src/main/java/org/apache/sling/maven/projectsupport/PrepareTestWebAppMojo.java b/src/main/java/org/apache/sling/maven/projectsupport/PrepareTestWebAppMojo.java
index 229c894..d38d1cf 100644
--- a/src/main/java/org/apache/sling/maven/projectsupport/PrepareTestWebAppMojo.java
+++ b/src/main/java/org/apache/sling/maven/projectsupport/PrepareTestWebAppMojo.java
@@ -60,9 +60,10 @@ public class PrepareTestWebAppMojo extends PreparePackageMojo {
*/
private ArtifactHandlerManager artifactHandlerManager;
+ @Override
public void executeWithArtifacts() throws MojoExecutionException, MojoFailureException {
super.executeWithArtifacts();
- copy(getPrimaryArtifact(), startLevel, getOutputDirectory());
+ copy(getPrimaryArtifact(), startLevel, null, getOutputDirectory());
}
@Override
diff --git a/src/main/mdo/bundle-list.xml b/src/main/mdo/bundle-list.xml
index dbe123a..0bb9d5c 100644
--- a/src/main/mdo/bundle-list.xml
+++ b/src/main/mdo/bundle-list.xml
@@ -107,6 +107,11 @@
<type>int</type>
<required>true</required>
</field>
+ <field>
+ <name>runModes</name>
+ <version>1.0.0</version>
+ <type>String</type>
+ </field>
</fields>
</class>
</classes>
--
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.
[sling-maven-launchpad-plugin] 02/10: SLING-2589 : Project
Configurations are overwritten by inherited
Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
rombert pushed a commit to annotated tag maven-launchpad-plugin-2.2.0
in repository https://gitbox.apache.org/repos/asf/sling-maven-launchpad-plugin.git
commit bf9822b977288b71eb1743d7d45e5204fbd2b054
Author: Carsten Ziegeler <cz...@apache.org>
AuthorDate: Thu Aug 30 14:31:43 2012 +0000
SLING-2589 : Project Configurations are overwritten by inherited
git-svn-id: https://svn.apache.org/repos/asf/sling/trunk/maven/maven-launchpad-plugin@1378957 13f79535-47bb-0310-9956-ffa450edef68
---
.../AbstractUsingBundleListMojo.java | 28 ++++++++++------------
1 file changed, 13 insertions(+), 15 deletions(-)
diff --git a/src/main/java/org/apache/sling/maven/projectsupport/AbstractUsingBundleListMojo.java b/src/main/java/org/apache/sling/maven/projectsupport/AbstractUsingBundleListMojo.java
index 991f2be..34a8b02 100644
--- a/src/main/java/org/apache/sling/maven/projectsupport/AbstractUsingBundleListMojo.java
+++ b/src/main/java/org/apache/sling/maven/projectsupport/AbstractUsingBundleListMojo.java
@@ -239,7 +239,7 @@ public abstract class AbstractUsingBundleListMojo extends AbstractBundleListMojo
for (Artifact artifact : dependencies) {
if (PARTIAL.equals(artifact.getType())) {
getLog().info(
- String.format("merging partial bundle list for %s:%s:%s", artifact.getGroupId(),
+ String.format("Merging partial bundle list %s:%s:%s", artifact.getGroupId(),
artifact.getArtifactId(), artifact.getVersion()));
initializedBundleList.merge(readBundleList(artifact.getFile()));
}
@@ -263,15 +263,17 @@ public abstract class AbstractUsingBundleListMojo extends AbstractBundleListMojo
final Set<Artifact> dependencies = project.getDependencyArtifacts();
for (Artifact artifact : dependencies) {
if (PARTIAL.equals(artifact.getType())) {
- getLog().info(
- String.format("merging configuration from partial bundle list for %s:%s:%s", artifact.getGroupId(),
- artifact.getArtifactId(), artifact.getVersion()));
extractConfiguration(artifact);
}
}
+ // copy own config files
+ if ( this.overlayConfigDir != null && super.getConfigDirectory().exists() ) {
+ FileUtils.copyDirectory(super.getConfigDirectory(), this.overlayConfigDir,
+ null, FileUtils.getDefaultExcludesAsString());
+ }
}
- private void extractConfiguration(Artifact artifact) throws MojoExecutionException, IOException {
+ private void extractConfiguration(final Artifact artifact) throws MojoExecutionException, IOException {
// check for configuration artifact
Artifact cfgArtifact = null;
try {
@@ -285,7 +287,7 @@ public abstract class AbstractUsingBundleListMojo extends AbstractBundleListMojo
}
if ( cfgArtifact != null ) {
getLog().info(
- String.format("merging partial bundle list configuration for %s:%s:%s", cfgArtifact.getGroupId(),
+ String.format("Merging settings from partial bundle list %s:%s:%s", cfgArtifact.getGroupId(),
cfgArtifact.getArtifactId(), cfgArtifact.getVersion()));
// extract
@@ -304,17 +306,13 @@ public abstract class AbstractUsingBundleListMojo extends AbstractBundleListMojo
this.readSlingBootstrap(new File(slingDir, AttachPartialBundleListMojo.SLING_STANDALONE_BOOTSTRAP), 2);
// and now configurations
- if ( this.overlayConfigDir == null ) {
- this.tempConfigDir.mkdirs();
- if ( this.getConfigDirectory().exists() ) {
- FileUtils.copyDirectory(this.getConfigDirectory(), this.tempConfigDir,
- null, FileUtils.getDefaultExcludesAsString());
- }
- this.overlayConfigDir = this.tempConfigDir;
- }
final File configDir = new File(this.tmpOutputDir, "config");
if ( configDir.exists() ) {
- FileUtils.copyDirectory(configDir, this.tempConfigDir,
+ if ( this.overlayConfigDir == null ) {
+ this.tempConfigDir.mkdirs();
+ this.overlayConfigDir = this.tempConfigDir;
+ }
+ FileUtils.copyDirectory(configDir, this.overlayConfigDir,
null, FileUtils.getDefaultExcludesAsString());
}
} catch (final ArchiverException ae) {
--
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.