assets-maven-plugin

Sonatype helps open source projects to set up Maven repositories on https://oss.sonatype.org/

License

License

Categories

Categories

Maven Build Tools Net
GroupId

GroupId

net.unit8.maven.plugins
ArtifactId

ArtifactId

assets-maven-plugin
Last Version

Last Version

0.2.0
Release Date

Release Date

Type

Type

maven-plugin
Description

Description

assets-maven-plugin
Sonatype helps open source projects to set up Maven repositories on https://oss.sonatype.org/
Source Code Management

Source Code Management

https://github.com/kawasima/assets-maven-plugin.git

Download assets-maven-plugin

How to add to project

<plugin>
    <groupId>net.unit8.maven.plugins</groupId>
    <artifactId>assets-maven-plugin</artifactId>
    <version>0.2.0</version>
</plugin>

Dependencies

compile (5)

Group / Artifact Type Version
org.yaml : snakeyaml jar 1.10
commons-io : commons-io jar 2.4
org.lesscss : lesscss jar 1.7.0.1.1
com.google.javascript : closure-compiler jar v20140625
com.google.closure-stylesheets : closure-stylesheets jar 20140426

provided (2)

Group / Artifact Type Version
org.apache.maven : maven-plugin-api jar 3.2.2
org.apache.maven.plugin-tools : maven-plugin-annotations jar 3.3

test (6)

Group / Artifact Type Version
junit : junit jar 4.11
org.apache.maven : maven-compat jar 3.2.2
org.eclipse.sisu : org.eclipse.sisu.plexus jar 0.2.1
com.google.inject : guice jar 3.0
org.apache.maven.plugin-testing : maven-plugin-testing-harness jar 3.1.0
org.apache.maven.plugin-testing : maven-plugin-testing-tools jar 3.1.0

Project Modules

There are no modules declared in this project.

Assets maven plugin

This is the maven plugin for minifing and aggregatings the stylesheet and javascript files. It can precompile LESS or Coffeescript sources.

Goals

Goal Description
assets:aggregate Aggregate asset files according to the recipe file.

assets:aggregate

Full name :net.unit8.maven.plugins:assets-maven-plugin:0.2.0-SNAPSHOT:aggregate

Description :Aggregate asset files according to the recipe file.

Optional parameters

Name Type Description
recipeFile String Recipe file path
encoding String charset of source files
workingDirectory String The base directory of working files
auto Boolean Wherher auto re-aggregate When source files are changed,

Recipe file

The recipe file is written how to aggregate asset files.

sourceDirectory: src/main/webapp
targetDirectory: src/main/webapp
precompilers: [ less, coffee ]
rules:
  - target: js/all.js
    version: 1.7
    components:
      - js/*.js
      - js/*.coffee
  - target: css/all.css
    version: 1.7
    minify: true
    components:
      - css/a1.css
      - css/a2.css
      - css/a3.less
Name Description
sourceDirectory The base directory of components
targetDirectory The base directory of targets
precompilers If assets is needed to precompile, this precompilers works.
target This is aggregated file.
version If the version is set, the name of target file
minify If this is set true, minify the aggregated asset file.
components This is subject to aggregate.

License

Copyright 2012 kawasima

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Versions

Version
0.2.0
0.1.1