Cache manifest generator

Atteo Parent POM

License

License

Apache License, Version 2.0
Categories

Categories

Maven Build Tools
GroupId

GroupId

org.atteo
ArtifactId

ArtifactId

cachemanifest-maven-plugin
Last Version

Last Version

0.2
Release Date

Release Date

Type

Type

maven-plugin
Description

Description

Cache manifest generator
Atteo Parent POM
Project Organization

Project Organization

Atteo
Source Code Management

Source Code Management

https://github.com/atteo/cachemanifest-maven-plugin

Download cachemanifest-maven-plugin

How to add to project

<plugin>
    <groupId>org.atteo</groupId>
    <artifactId>cachemanifest-maven-plugin</artifactId>
    <version>0.2</version>
</plugin>

Dependencies

compile (4)

Group / Artifact Type Version
org.apache.maven : maven-plugin-api jar 3.2.1
org.apache.maven.shared : file-management jar 1.2.1
org.apache.maven : maven-project jar 3.0-alpha-2
org.jsoup : jsoup jar 1.7.2

provided (1)

Group / Artifact Type Version
org.apache.maven.plugin-tools : maven-plugin-annotations jar 3.2

Project Modules

There are no modules declared in this project.

Arguments

  • manifestPath - where to put yout manifest file
  • manifestVersion - manifest file version, will be included in a comment in the file. If left empty version will be taken from the pom. If pom version is a snapshot a timestamp will be added to it
  • fileResources - add a tree to the manifest (see example below)
  • resourcesReferencedFrom - add scripts and css stylesheets referenced from an html file
  • resources - add resources manually
  • networkResources - network section
  • fallback - fallback section

Changes

Version 0.3

  • always use '/' in URLs

Version 0.2

  • initial release

Example

<build>
    <plugins>
        <plugin>
            <groupId>org.atteo</groupId>
            <artifactId>cachemanifest-maven-plugin</artifactId>
            <version>0.3</version>
            <executions>
                <execution>
                    <phase>process-resources</phase>
                    <goals>
                        <goal>generate-manifest</goal>
                    </goals>
                </execution>
            </executions>
            <configuration>
                <manifestPath>${project.build.directory}/classes/META-INF/resources/webapp/application.cachemanifest</manifestPath>

                <!-- main app files -->
                <fileResources>
                    <fileResource>
                        <directory>${project.build.directory}/classes/META-INF/resources/webapp</directory>
                        <includes>
                            <include>app/**/*.*</include>
                        </includes>
                        <excludes>
                            <exclude>app/scss/**/*.*</exclude>
                        </excludes>
                    </fileResource>
                </fileResources>

                <!-- webjars -->
                <resourcesReferencedFrom>
                    <param>src/main/webapp/index.html</param>
                </resourcesReferencedFrom>

                <!-- resources referenced from outside CSS files -->
                <resources>
                    <resource>app/css/fontello/font/fontello.woff?69525316</resource>
                    <resource>app/css/fontello/font/fontello.ttf?69525316</resource>
                    <resource>app/css/fontello/font/fontello.svg?69525316</resource>
                    <resource>app/css/fonts/font-awesome/fontawesome-webfont.woff?v=4.0.3</resource>
                    <resource>app/css/fonts/font-awesome/fontawesome-webfont.ttf?v=4.0.3</resource>
                    <resource>app/css/fonts/font-awesome/fontawesome-webfont.svg?v=4.0.3</resource>
                </resources>

                <networkResources>
                    <param>*</param>
                </networkResources>
            </configuration>
        </plugin>
    </plugins>
</build>

License

Apache License 2.0.

org.atteo

Atteo

Versions

Version
0.2