-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathpom.xml
153 lines (147 loc) · 4.93 KB
/
pom.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
<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>org.durcframework</groupId>
<artifactId>autoCode</artifactId>
<version>1.0.0</version>
<dependencies>
<dependency>
<groupId>net.oschina.durcframework</groupId>
<artifactId>durcframework-core</artifactId>
<version>1.0.4</version>
</dependency>
<dependency>
<groupId>com.alibaba</groupId>
<artifactId>druid</artifactId>
<version>1.0.4</version>
</dependency>
<dependency>
<groupId>org.apache.velocity</groupId>
<artifactId>velocity</artifactId>
<version>1.7</version>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.8</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.apache.tomcat</groupId>
<artifactId>servlet-api</artifactId>
<version>6.0.29</version>
<scope>provided</scope>
</dependency>
<!-- 支持的数据源,默认已经支持mysql -->
<dependency>
<groupId>net.sourceforge.jtds</groupId>
<artifactId>jtds</artifactId>
<version>1.2.2</version>
</dependency>
</dependencies>
<build>
<finalName>autoCode</finalName>
<plugins>
<!-- mvn jetty:run -->
<plugin>
<groupId>org.mortbay.jetty</groupId>
<artifactId>maven-jetty-plugin</artifactId>
<version>6.0.0alpha3</version>
<configuration>
<contextPath>/autoCode</contextPath>
<connectors>
<connector implementation="org.mortbay.jetty.nio.SelectChannelConnector">
<port>8088</port>
</connector>
</connectors>
<reload>automatic</reload>
<scanIntervalSeconds>3</scanIntervalSeconds>
<systemProperties>
<systemProperty>
<name>org.mortbay.util.URI.charset</name>
<value>UTF-8</value>
</systemProperty>
</systemProperties>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>1.6</source>
<target>1.6</target>
<encoding>UTF-8</encoding>
</configuration>
</plugin>
<plugin>
<!-- YUI Compressor Maven压缩插件 -->
<groupId>net.alchim31.maven</groupId>
<artifactId>yuicompressor-maven-plugin</artifactId>
<version>1.3.0</version>
<configuration>
<!-- 读取js,css文件采用UTF-8编码 -->
<encoding>UTF-8</encoding>
<!-- 不显示js可能的错误 -->
<jswarn>false</jswarn>
<!-- 若存在已压缩的文件,会先对比源文件是否有改动。有改动便压缩,无改动就不压缩 -->
<force>false</force>
<!-- 在指定的列号后插入新行 -->
<linebreakpos>-1</linebreakpos>
<!-- 压缩之前先执行聚合文件操作 -->
<preProcessAggregates>true</preProcessAggregates>
<!-- 压缩后保存文件后缀 -->
<suffix>.min</suffix>
<!-- 源目录,即需压缩的根目录 -->
<sourceDirectory>src/main/webapp</sourceDirectory>
<!-- 压缩js和css文件 -->
<includes>
<!-- 只压缩src/main/webapp/js/common.js -->
<include>js/common.js</include>
</includes>
<!-- 以下目录和文件不会被压缩 -->
<excludes>
<exclude>easyui/locale/*.js</exclude>
<exclude>easyui/themes/*.css</exclude>
</excludes>
<!-- 压缩后输出文件目录 -->
<outputDirectory>src/main/webapp</outputDirectory>
<!-- 聚合文件 -->
<aggregations>
<aggregation>
<!-- 合并每一个文件后插入一新行 -->
<insertNewLine>true</insertNewLine>
<!-- 需合并文件的根文件夹 -->
<inputDir>src/main/webapp/js</inputDir>
<!-- 最终合并的输出文件 -->
<output>src/main/webapp/js/common.js</output>
<!-- 把以下js文件合并成一个js文件,是按顺序合并的 -->
<!--
运行命令mvn yuicompressor:compress
会把下面几个js文件压缩到src/main/webapp/js/common.js中
并生成一个common.min.js
不会影响到其它js,css
-->
<includes>
<include>Action.js</include>
<include>Crud.js</include>
<include>EventUtil.js</include>
<include>FunUtil.js</include>
<include>HtmlUtil.js</include>
<include>MaskUtil.js</include>
<include>MsgUtil.js</include>
<include>VelocityContext.js</include>
</includes>
</aggregation>
</aggregations>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-war-plugin</artifactId>
<configuration>
<warSourceDirectory>src/main/webapp</warSourceDirectory>
</configuration>
</plugin>
</plugins>
</build>
</project>