Skip to content
This repository has been archived by the owner on Mar 15, 2021. It is now read-only.

Commit

Permalink
Merge branch 'release/2.0.0'
Browse files Browse the repository at this point in the history
# Conflicts:
#	README.md
#	pom.xml
  • Loading branch information
agabrys committed Dec 28, 2017
2 parents b2b01d1 + 6c7fc95 commit 6f1be64
Show file tree
Hide file tree
Showing 30 changed files with 275 additions and 190 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
/.classpath
/.project
/.settings
/src/site/resources/files/
/target
3 changes: 1 addition & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
language: java
script: mvn -e clean install site
jdk:
- oraclejdk9
- oraclejdk8
- oraclejdk7
- openjdk7
- openjdk6
10 changes: 10 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,15 @@
# Directory Content Maven Plugin Changelog

## 2.0.0
Features:
* Set compatibility with Java 6+
* Set compatibility with Maven 3+

Dependencies:
* Upgraded [Maven Plugin Utils](http://maven-plugin-utils.projects.gabrys.biz/) from [1.4.0](http://maven-plugin-utils.projects.gabrys.biz/1.4.0/) to [2.0.0](http://maven-plugin-utils.projects.gabrys.biz/2.0.0/)

[See documentation](http://directory-content-maven-plugin.projects.gabrys.biz/2.0.0/)

## 1.2.1
Bugs:
* Added missing Eclipse `lifecycleMappingMetadata` for the [copyFile](http://directory-content-maven-plugin.projects.gabrys.biz/1.2.1/copyFile-mojo.html) goal
Expand Down
16 changes: 6 additions & 10 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -17,22 +17,18 @@ node {
stage('Checkout') {
checkout scm
}

withMaven(maven: 'MVN-3', jdk: 'JDK-8', mavenLocalRepo: '.repository') {
stage('Build') {
stage('Build') {
withMaven(maven: 'MVN-3', jdk: 'JDK-9', mavenLocalRepo: '.repository', options: [junitPublisher(disabled: true)]) {
sh 'mvn -e install site -DskipTests'
}
stage('Test') {
}
stage('Test') {
withMaven(maven: 'MVN-3', jdk: 'JDK-9', mavenLocalRepo: '.repository', options: [openTasksPublisher(disabled: true), dependenciesFingerprintPublisher(disabled: true)]) {
sh 'mvn -e test'
junit 'target/surefire-reports/TEST-*.xml'
}
}

stage('Archive') {
archiveArtifacts artifacts: 'target/*.jar', fingerprint: true
}
stage('Post Build Cleanup') {
step($class: 'WsCleanup')
}
}
}
}
28 changes: 14 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,29 +5,29 @@
Provides a collection of tools for working with directories.

# Goals Overview
* [directory-content:copy](http://directory-content-maven-plugin.projects.gabrys.biz/1.2.1/copy-mojo.html) - copies files to directory
* [directory-content:copyFile](http://directory-content-maven-plugin.projects.gabrys.biz/1.2.1/copyFile-mojo.html) - copies file from source to output directory (allow to change name)
* [directory-content:transformList](http://directory-content-maven-plugin.projects.gabrys.biz/1.2.1/transformList-mojo.html) - transforms files list to a document using [XSLT](http://www.w3.org/TR/xslt) technology
* [directory-content:transformMetadata](http://directory-content-maven-plugin.projects.gabrys.biz/1.2.1/transformMetadata-mojo.html) - transforms files metadata to documents using [XSLT](http://www.w3.org/TR/xslt) technology
* [directory-content:copy](http://directory-content-maven-plugin.projects.gabrys.biz/2.0.0/copy-mojo.html) - copies files to directory
* [directory-content:copyFile](http://directory-content-maven-plugin.projects.gabrys.biz/2.0.0/copyFile-mojo.html) - copies file from source to output directory (allow to change name)
* [directory-content:transformList](http://directory-content-maven-plugin.projects.gabrys.biz/2.0.0/transformList-mojo.html) - transforms files list to a document using [XSLT](http://www.w3.org/TR/xslt) technology
* [directory-content:transformMetadata](http://directory-content-maven-plugin.projects.gabrys.biz/2.0.0/transformMetadata-mojo.html) - transforms files metadata to documents using [XSLT](http://www.w3.org/TR/xslt) technology

# Requirements
The plugin to run requires:
* Java 5.0 or higher
* Maven 2.0.11 or higher
* Java 6 or higher
* Maven 3 or higher

# Usage
General instructions on how to use the Directory Content Maven Plugin can be found on the [usage](http://directory-content-maven-plugin.projects.gabrys.biz/1.2.1/usage.html) page. Some more specific use cases are described in the examples given below. Last but not least, users occasionally contribute additional examples, tips or errata to the plugin's [wiki](https://github.com/gabrysbiz/directory-content-maven-plugin/wiki) page.
General instructions on how to use the Directory Content Maven Plugin can be found on the [usage](http://directory-content-maven-plugin.projects.gabrys.biz/2.0.0/usage.html) page. Some more specific use cases are described in the examples given below. Last but not least, users occasionally contribute additional examples, tips or errata to the plugin's [wiki](https://github.com/gabrysbiz/directory-content-maven-plugin/wiki) page.

In case you still have questions regarding the plugin's usage, please have a look at the [FAQ](http://directory-content-maven-plugin.projects.gabrys.biz/1.2.1/faq.html).
In case you still have questions regarding the plugin's usage, please have a look at the [FAQ](http://directory-content-maven-plugin.projects.gabrys.biz/2.0.0/faq.html).

If you feel like the plugin is missing a feature or has a defect, you can fill a feature request or bug report in the [issue tracker](http://directory-content-maven-plugin.projects.gabrys.biz/1.2.1/issue-tracking.html). When creating a new issue, please provide a comprehensive description of your concern. Especially for fixing bugs it is crucial that the developers can reproduce your problem. For this reason, entire debug logs, POMs or most preferably little demo projects attached to the issue are very much appreciated. Of course, patches are welcome, too. Contributors can check out the project from the [source repository](http://directory-content-maven-plugin.projects.gabrys.biz/1.2.1/source-repository.html) and will find supplementary information in the [guide to helping with Maven](http://maven.apache.org/guides/development/guide-helping.html).
If you feel like the plugin is missing a feature or has a defect, you can fill a feature request or bug report in the [issue tracker](http://directory-content-maven-plugin.projects.gabrys.biz/2.0.0/issue-tracking.html). When creating a new issue, please provide a comprehensive description of your concern. Especially for fixing bugs it is crucial that the developers can reproduce your problem. For this reason, entire debug logs, POMs or most preferably little demo projects attached to the issue are very much appreciated. Of course, patches are welcome, too. Contributors can check out the project from the [source repository](http://directory-content-maven-plugin.projects.gabrys.biz/2.0.0/source-repository.html) and will find supplementary information in the [guide to helping with Maven](http://maven.apache.org/guides/development/guide-helping.html).

# Examples
To provide you with better understanding of some usages of the Directory Content Maven Plugin, you can take a look into the following examples:
* [Using include/exclude patterns](http://directory-content-maven-plugin.projects.gabrys.biz/1.2.1/examples/patterns.html)
* [Copies files from source to output directory](http://directory-content-maven-plugin.projects.gabrys.biz/1.2.1/examples/copy.html)
* [Copies file to output directory with a new name](http://directory-content-maven-plugin.projects.gabrys.biz/1.2.1/examples/copyFile.html)
* [Transform files list to file with JavaScript imports](http://directory-content-maven-plugin.projects.gabrys.biz/1.2.1/examples/transform-list.html)
* [Transform files metadata to download files](http://directory-content-maven-plugin.projects.gabrys.biz/1.2.1/examples/transform-metadata.html)
* [Using include/exclude patterns](http://directory-content-maven-plugin.projects.gabrys.biz/2.0.0/examples/patterns.html)
* [Copies files from source to output directory](http://directory-content-maven-plugin.projects.gabrys.biz/2.0.0/examples/copy.html)
* [Copies file to output directory with a new name](http://directory-content-maven-plugin.projects.gabrys.biz/2.0.0/examples/copyFile.html)
* [Transform files list to file with JavaScript imports](http://directory-content-maven-plugin.projects.gabrys.biz/2.0.0/examples/transform-list.html)
* [Transform files metadata to download files](http://directory-content-maven-plugin.projects.gabrys.biz/2.0.0/examples/transform-metadata.html)

You can also fetch example projects from [GitHub](https://github.com/gabrysbiz/directory-content-maven-plugin-examples).
56 changes: 37 additions & 19 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@

<groupId>biz.gabrys.maven.plugins</groupId>
<artifactId>directory-content-maven-plugin</artifactId>
<version>1.2.1</version>
<version>2.0.0</version>
<packaging>maven-plugin</packaging>
<name>Directory Content Maven Plugin</name>
<description>Provides a collection of tools for working with directories.</description>
<url>http://directory-content-maven-plugin.projects.gabrys.biz/1.2.1/</url>
<url>http://directory-content-maven-plugin.projects.gabrys.biz/2.0.0/</url>

<inceptionYear>2015</inceptionYear>
<organization>
Expand Down Expand Up @@ -37,7 +37,7 @@
</developers>

<prerequisites>
<maven>2.0.11</maven>
<maven>3.0</maven>
</prerequisites>

<scm>
Expand Down Expand Up @@ -74,27 +74,26 @@
<dependency>
<groupId>org.apache.maven</groupId>
<artifactId>maven-plugin-api</artifactId>
<version>2.0.11</version>
<version>3.0</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.apache.maven.plugin-tools</groupId>
<artifactId>maven-plugin-annotations</artifactId>
<!-- latest compatible with JDK 1.5 -->
<version>3.4</version>
<version>3.5</version>
<scope>provided</scope>
</dependency>

<dependency>
<groupId>biz.gabrys.maven</groupId>
<artifactId>plugin-utils</artifactId>
<version>1.4.0</version>
<version>2.0.0</version>
</dependency>

<dependency>
<groupId>com.thoughtworks.xstream</groupId>
<artifactId>xstream</artifactId>
<!-- latest compatible with JDK 1.5 -->
<!-- latest compatible with JDK 6 -->
<version>1.4.7</version>
</dependency>

Expand All @@ -104,11 +103,17 @@
<version>4.12</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.assertj</groupId>
<artifactId>assertj-core</artifactId>
<!-- latest compatible with JDK 6 -->
<version>1.7.1</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.mockito</groupId>
<artifactId>mockito-core</artifactId>
<!-- latest compatible with JDK 1.5 -->
<version>1.10.19</version>
<version>2.13.0</version>
<scope>test</scope>
</dependency>
</dependencies>
Expand Down Expand Up @@ -140,7 +145,7 @@
</plugin>
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.6.1</version>
<version>3.7.0</version>
</plugin>
<plugin>
<artifactId>maven-deploy-plugin</artifactId>
Expand All @@ -165,6 +170,10 @@
<linkJavadoc>false</linkJavadoc>
</configuration>
</plugin>
<plugin>
<artifactId>maven-plugin-plugin</artifactId>
<version>3.5</version>
</plugin>
<plugin>
<artifactId>maven-project-info-reports-plugin</artifactId>
<version>2.9</version>
Expand All @@ -183,7 +192,7 @@
</plugin>
<plugin>
<artifactId>maven-surefire-plugin</artifactId>
<version>2.19.1</version>
<version>2.20.1</version>
</plugin>
<plugin>
<groupId>com.mycila</groupId>
Expand All @@ -192,7 +201,7 @@
<configuration>
<header>header-license-template.txt</header>
<properties>
<owner>Adam Gabryś</owner>
<owner>Adam Gabrys</owner>
</properties>
<includes>
<include>src/main/java/**</include>
Expand All @@ -205,7 +214,7 @@
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<version>0.7.8</version>
<version>0.7.9</version>
<configuration>
<rules>
<rule>
Expand Down Expand Up @@ -246,11 +255,21 @@
</plugins>
</pluginManagement>
<plugins>
<plugin>
<artifactId>maven-clean-plugin</artifactId>
<configuration>
<filesets>
<fileset>
<directory>src/site/resources/files</directory>
</fileset>
</filesets>
</configuration>
</plugin>
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>1.5</source>
<target>1.5</target>
<source>1.6</source>
<target>1.6</target>
<showDeprecation>true</showDeprecation>
<showWarnings>true</showWarnings>
</configuration>
Expand Down Expand Up @@ -295,13 +314,13 @@
<artifactId>maven-antrun-plugin</artifactId>
<executions>
<execution>
<phase>site</phase>
<phase>pre-site</phase>
<goals>
<goal>run</goal>
</goals>
<configuration>
<target>
<copy todir="${project.build.directory}/site/files">
<copy todir="src/site/resources/files">
<fileset dir="${project.build.directory}">
<include name="${project.artifactId}-${project.version}.jar" />
<include name="${project.artifactId}-${project.version}-sources.jar" />
Expand All @@ -327,7 +346,6 @@
<reports>
<report>cim</report>
<report>dependencies</report>
<report>dependency-info</report>
<report>issue-tracking</report>
<report>license</report>
<report>summary</report>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* Directory Content Maven Plugin
* http://directory-content-maven-plugin.projects.gabrys.biz/
*
* Copyright (c) 2015 Adam Gabryś
* Copyright (c) 2015 Adam Gabrys
*
* This file is licensed under the BSD 3-Clause (the "License").
* You may not use this file except in compliance with the License.
Expand Down Expand Up @@ -116,6 +116,7 @@ private void calculateParameters() {
}
}

@Override
public final void execute() throws MojoFailureException {
logParameters();
if (skip) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* Directory Content Maven Plugin
* http://directory-content-maven-plugin.projects.gabrys.biz/
*
* Copyright (c) 2015 Adam Gabryś
* Copyright (c) 2015 Adam Gabrys
*
* This file is licensed under the BSD 3-Clause (the "License").
* You may not use this file except in compliance with the License.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* Directory Content Maven Plugin
* http://directory-content-maven-plugin.projects.gabrys.biz/
*
* Copyright (c) 2015 Adam Gabryś
* Copyright (c) 2015 Adam Gabrys
*
* This file is licensed under the BSD 3-Clause (the "License").
* You may not use this file except in compliance with the License.
Expand Down Expand Up @@ -109,6 +109,7 @@ private boolean isOutputFilePathValid() {
return outputFilePath != null && outputFilePath.length() > 0;
}

@Override
public void execute() throws MojoFailureException {
logParameters();
if (shouldSkipExecution()) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* Directory Content Maven Plugin
* http://directory-content-maven-plugin.projects.gabrys.biz/
*
* Copyright (c) 2015 Adam Gabryś
* Copyright (c) 2015 Adam Gabrys
*
* This file is licensed under the BSD 3-Clause (the "License").
* You may not use this file except in compliance with the License.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* Directory Content Maven Plugin
* http://directory-content-maven-plugin.projects.gabrys.biz/
*
* Copyright (c) 2015 Adam Gabryś
* Copyright (c) 2015 Adam Gabrys
*
* This file is licensed under the BSD 3-Clause (the "License").
* You may not use this file except in compliance with the License.
Expand Down Expand Up @@ -114,7 +114,7 @@ private boolean isTransformationRequired(final Collection<File> files) {
return false;
}

private String transformToXml(final Collection<File> files) throws MojoFailureException {
private String transformToXml(final Collection<File> files) {
if (getLog().isDebugEnabled()) {
getLog().debug("Creating metadata...");
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* Directory Content Maven Plugin
* http://directory-content-maven-plugin.projects.gabrys.biz/
*
* Copyright (c) 2015 Adam Gabryś
* Copyright (c) 2015 Adam Gabrys
*
* This file is licensed under the BSD 3-Clause (the "License").
* You may not use this file except in compliance with the License.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* Directory Content Maven Plugin
* http://directory-content-maven-plugin.projects.gabrys.biz/
*
* Copyright (c) 2015 Adam Gabryś
* Copyright (c) 2015 Adam Gabrys
*
* This file is licensed under the BSD 3-Clause (the "License").
* You may not use this file except in compliance with the License.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* Directory Content Maven Plugin
* http://directory-content-maven-plugin.projects.gabrys.biz/
*
* Copyright (c) 2015 Adam Gabryś
* Copyright (c) 2015 Adam Gabrys
*
* This file is licensed under the BSD 3-Clause (the "License").
* You may not use this file except in compliance with the License.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* Directory Content Maven Plugin
* http://directory-content-maven-plugin.projects.gabrys.biz/
*
* Copyright (c) 2015 Adam Gabryś
* Copyright (c) 2015 Adam Gabrys
*
* This file is licensed under the BSD 3-Clause (the "License").
* You may not use this file except in compliance with the License.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* Directory Content Maven Plugin
* http://directory-content-maven-plugin.projects.gabrys.biz/
*
* Copyright (c) 2015 Adam Gabryś
* Copyright (c) 2015 Adam Gabrys
*
* This file is licensed under the BSD 3-Clause (the "License").
* You may not use this file except in compliance with the License.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* Directory Content Maven Plugin
* http://directory-content-maven-plugin.projects.gabrys.biz/
*
* Copyright (c) 2015 Adam Gabryś
* Copyright (c) 2015 Adam Gabrys
*
* This file is licensed under the BSD 3-Clause (the "License").
* You may not use this file except in compliance with the License.
Expand Down
Loading

0 comments on commit 6f1be64

Please sign in to comment.