This is an automated email from the ASF dual-hosted git repository. rombert pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/sling-initial-content-archetype.git
commit 61434c18e1551037e806127e2b802f92091fb27e Author: Robert Munteanu <[email protected]> AuthorDate: Thu May 15 08:36:08 2014 +0000 SLING-3520 - Consolidate archetype plugin versions in a parent pom Update all archetypes to use the archetype parent. Projects missing verification now run a simple verify script which validates that the build was successful and no warnings were generated. git-svn-id: https://svn.apache.org/repos/asf/sling/trunk@1594818 13f79535-47bb-0310-9956-ffa450edef68 --- pom.xml | 15 ++++----------- src/main/resources/archetype-resources/pom.xml | 19 ++++++++++++------- .../resources/projects/normal/archetype.properties | 4 ++++ src/test/resources/projects/normal/goal.txt | 1 + src/test/resources/projects/normal/verify.groovy | 9 +++++++++ 5 files changed, 30 insertions(+), 18 deletions(-) diff --git a/pom.xml b/pom.xml index ebfba1e..6db9353 100644 --- a/pom.xml +++ b/pom.xml @@ -21,9 +21,9 @@ <modelVersion>4.0.0</modelVersion> <parent> <groupId>org.apache.sling</groupId> - <artifactId>sling</artifactId> - <version>19</version> - <relativePath>../../../parent/pom.xml</relativePath> + <artifactId>sling-archetype-parent</artifactId> + <version>1</version> + <relativePath>../parent/pom.xml</relativePath> </parent> <artifactId>sling-initial-content-archetype</artifactId> @@ -44,16 +44,9 @@ <extension> <groupId>org.apache.maven.archetype</groupId> <artifactId>archetype-packaging</artifactId> - <version>2.0-alpha-4</version> + <version>${archetype.version}</version> </extension> </extensions> - <plugins> - <plugin> - <artifactId>maven-archetype-plugin</artifactId> - <version>2.0-alpha-4</version> - <extensions>true</extensions> - </plugin> - </plugins> </build> <reporting> diff --git a/src/main/resources/archetype-resources/pom.xml b/src/main/resources/archetype-resources/pom.xml index 64e92ce..e81b14e 100644 --- a/src/main/resources/archetype-resources/pom.xml +++ b/src/main/resources/archetype-resources/pom.xml @@ -19,21 +19,23 @@ --> <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> <modelVersion>4.0.0</modelVersion> - <groupId>${groupId}</groupId> - <artifactId>${artifactId}</artifactId> + <groupId>\${groupId}</groupId> + <artifactId>\${artifactId}</artifactId> <packaging>bundle</packaging> - <version>${version}</version> - <name>${artifactId}</name> - <description>${groupId} - ${artifactId}</description> + <version>\${version}</version> + <name>\${artifactId}</name> + <description>\${groupId} - \${artifactId}</description> <build> <plugins> <plugin> <groupId>org.apache.felix</groupId> <artifactId>maven-bundle-plugin</artifactId> <extensions>true</extensions> - <version>2.0.1</version> + <version>${bundleplugin.version}</version> <configuration> <instructions> + <!-- Stop bnd complaining about unused Private-Package instructions --> + <Private-Package></Private-Package> <Sling-Nodetypes> SLING-INF/nodetypes/nodetypes.cnd </Sling-Nodetypes> @@ -54,7 +56,7 @@ <plugin> <groupId>org.apache.sling</groupId> <artifactId>maven-sling-plugin</artifactId> - <version>2.0.4-incubator</version> + <version>${slingplugin.version}</version> <executions> <execution> <id>install-bundle</id> @@ -73,4 +75,7 @@ </build> </profile> </profiles> + <properties> + <project.build.sourceEncoding>${project.build.sourceEncoding}</project.build.sourceEncoding> + </properties> </project> diff --git a/src/test/resources/projects/normal/archetype.properties b/src/test/resources/projects/normal/archetype.properties new file mode 100644 index 0000000..8912113 --- /dev/null +++ b/src/test/resources/projects/normal/archetype.properties @@ -0,0 +1,4 @@ +groupId=org.apache.sling +artifactId=test-bundle-archetype-project +version=0.0.1-SNAPSHOT +package=org.apache.sling.archetype.initialcontent.testing \ No newline at end of file diff --git a/src/test/resources/projects/normal/goal.txt b/src/test/resources/projects/normal/goal.txt new file mode 100644 index 0000000..4a1a71d --- /dev/null +++ b/src/test/resources/projects/normal/goal.txt @@ -0,0 +1 @@ +verify \ No newline at end of file diff --git a/src/test/resources/projects/normal/verify.groovy b/src/test/resources/projects/normal/verify.groovy new file mode 100644 index 0000000..8e4bc97 --- /dev/null +++ b/src/test/resources/projects/normal/verify.groovy @@ -0,0 +1,9 @@ +new File(basedir, '.').eachFileRecurse(groovy.io.FileType.FILES) { logFile -> + if ( logFile.name == "build.log" ) { + logFile.eachLine { line -> + if ( line.contains("WARNING") ) { + throw new RuntimeException("Warning found in line ${line}\nIn file ${logFile}"); + } + } + } +} \ No newline at end of file -- To stop receiving notification emails like this one, please contact "[email protected]" <[email protected]>.
