• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

tqh/uglifyjs-maven-plugin: A maven plugin that runs uglifyjs on a directory of j ...

原作者: [db:作者] 来自: 网络 收藏 邀请

开源软件名称(OpenSource Name):

tqh/uglifyjs-maven-plugin

开源软件地址(OpenSource Url):

https://github.com/tqh/uglifyjs-maven-plugin

开源编程语言(OpenSource Language):

Java 92.2%

开源软件介绍(OpenSource Introduction):

uglifyjs-maven-plugin

A maven plugin that runs UglifyJS on a directory of javascript files.

Based on the excellent https://github.com/kawasima/handlebars-maven-plugin

Introduction

uglifyjs-maven-plugin is used to run UglifyJS on the javascript files of your project.

Goals

Goal Description
uglifyjs:uglify Compress javascript files

uglifyjs:uglify

Full name :net.tqh.plugins:uglifyjs-maven-plugin:1.0:uglify

Description :uglify Run UglifyJS on files in sourceDirectory.

Optional parameters

Name Type Description
skip Boolean Flag that allows user to skip execution of the plugin. (Currently only available when building this plugin from source.)
sources FileSet The directory containing javascript source files.
outputDirectory String The output directory to put uglified files.
encoding String Charset of javascript files.

Repo

If you want to use this plugin in your maven project add the following plugin repository

<pluginRepositories>
  <pluginRepository>
    <id>uglifyjs-maven-plugin</id>
    <url>https://raw.github.com/tqh/uglifyjs-maven-plugin/master/repo</url>
  </pluginRepository>
</pluginRepositories>

and call the plugin during the build process, e.g.:

<build>
    <plugins>
        <plugin>
            <groupId>net.tqh.plugins</groupId>
            <artifactId>uglifyjs-maven-plugin</artifactId>
            <version>1.0</version>
            <executions>
                <execution>
                    <id>uglify-js</id>
                    <phase>compile</phase>
                    <goals>
                        <goal>uglify</goal>
                    </goals>
                    <configuration>
                        <skip>false</skip>
                        <sources>
                            <directory>${project.build.directory}/classes/js</directory>
                            <excludes>
                                <exclude>org/foo</exclude>
                                <exclude>org/bar</exclude>
                                <exclude>**/*.min.js</exclude>
                            </excludes>
                            <includes>
                                <include>org/foo/lib</include>
                            </includes>
                        </sources>
                        <outputDirectory>${project.build.directory}/classes/js</outputDirectory>
                    </configuration>
                </execution>
            </executions>
        </plugin>
    </plugins>
</build>



鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
s4u/maven-settings-action: This action setup maven settings.xml发布时间:2022-08-17
下一篇:
code-not-found/spring-batch: Spring Batch Tutorials发布时间:2022-08-17
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap