Maven之自定义pom类型的基础项目
摘要:在当前的软件开发场景中,大都是通过maven管理项目,而如果使用maven的话,其实也会有很多问题,比如项目中依赖的版本管理就
是一个很头疼的事,如果一个项目中有很多人同时开发那么这就很可能造成大家添加的依赖的版本不一致的情况,那样的话会给项目开发
带来很多不必要的麻烦,所以为了让所有的依赖的版本能一致,就需要我们先自定义一个统一依赖版本的基础项目,其他的项目在引用依赖
的时候直接继承该项目即可,这样所有的开发人员使用的依赖版本就能保持一致性。
一:micaicms-pom项目的pom.xml:
- <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/xsd/maven-4.0.0.xsd">
- <modelVersion>4.0.0</modelVersion>
- <groupId>org.micaicms</groupId>
- <artifactId>micaicms-pom</artifactId>
- <version>1.0</version>
- <packaging>pom</packaging>
- <name>MICAICMS POM</name>
- <description>MICAICMS ROOT POM</description>
- <properties>
- <!-- 前端 Java开发工具 -->
- <!-- 1.Servlet -->
- <servlet-api.version>3.0.1</servlet-api.version>
- <!-- 2.Jsp -->
- <jsp-api.version>2.2</jsp-api.version>
- <!-- 3.Jstl -->
- <jstl.version>1.2</jstl.version>
- <standard.version>1.1.2</standard.version>
- <!-- 4.Echart-java -->
- <ECharts.version>2.1.8.3</ECharts.version>
- <!-- 5.Freemarker -->
- <freemarker.version>2.3.2</freemarker.version>
- <!-- 6.Json -->
- <jackson.version>1.9.13</jackson.version>
- <jackson-databind.version>2.5.1</jackson-databind.version>
- <!-- Spring -->
- <spring-framework.version>4.0.6.RELEASE</spring-framework.version>
- <!-- 面向切面工具 -->
- <aspectjweaver.version>1.8.1</aspectjweaver.version>
- <!-- 文本处理工具 -->
- <!-- 1.Dom4j -->
- <dom4j.version>1.6.1</dom4j.version>
- <!-- 2.Poi -->
- <poi.version>3.10-FINAL</poi.version>
- <!-- 3.IText -->
- <itext.version>5.5.4</itext.version>
- <!-- 数据库开发工具 -->
- <!-- 1.tomcat-jdbc -->
- <tomcat-jdbc.version>7.0.52</tomcat-jdbc.version>
- <!-- 2.Mybatis -->
- <mybatis.version>3.2.2</mybatis.version>
- <mybatis-paginator.version>1.2.15</mybatis-paginator.version>
- <mybatis-spring.version>1.2.2</mybatis-spring.version>
- <!-- 3.Mysql connector -->
- <mysql-connector.version>5.1.30</mysql-connector.version>
- <!-- 日志工具 -->
- <!-- 1.slf4j -->
- <slf4j.version>1.7.7</slf4j.version>
- <!-- 2.log4j -->
- <log4j.version>2.1</log4j.version>
- <!-- Quartz -->
- <quartz.version>2.1.7</quartz.version>
- <!-- Activiti -->
- <activiti.version>5.16.3</activiti.version>
- <!-- cas_client -->
- <cas_client.version>3.3.0</cas_client.version>
- <!-- Test -->
- <junit.version>4.10</junit.version>
- <!-- JDK -->
- <jdk.version>1.8</jdk.version>
- <!-- 后台验证工具 -->
- <!-- 1.hibernate-validator -->
- <hibernate-validator.version>5.1.3.Final</hibernate-validator.version>
- <!-- 文件上传工具 -->
- <!-- 1.commons-fileupload -->
- <commons-fileupload.version>1.3.1</commons-fileupload.version>
- <!-- 润乾报表工具 -->
- <!-- 1.runqian_report -->
- <runqian.version>4.5.0-RELEASE</runqian.version>
- <!-- 1.ckeditor -->
- <ckeditor.version>4.4.7</ckeditor.version>
- <!-- 2.bootstrap -->
- <bootstrap.version>3.3.0</bootstrap.version>
- <!-- 3.echarts -->
- <echarts.version>2.1.10</echarts.version>
- <!-- 4.jquery -->
- <jquery.version>1.11.1</jquery.version>
- <!-- 5.jqwidgets -->
- <jqwidgets.version>3.8.0</jqwidgets.version>
- <jquery-ui.version>1.11.1</jquery-ui.version>
- <jquery-form.version>3.51</jquery-form.version>
- <!-- 校验工具 -->
- <jquery.validate.js.version>1.13.1</jquery.validate.js.version>
- <!-- 文件上传工具 -->
- <jquery-file-upload.version>9.8.1</jquery-file-upload.version>
- </properties>
- <dependencyManagement>
- <dependencies>
- <!-- 前端 Java开发工具 -->
- <!-- 1.Servlet -->
- <dependency>
- <groupId>javax.servlet</groupId>
- <artifactId>javax.servlet-api</artifactId>
- <version>${servlet-api.version}</version>
- <scope>provided</scope>
- </dependency>
- <!-- 2.Jsp -->
- <dependency>
- <groupId>javax.servlet.jsp</groupId>
- <artifactId>jsp-api</artifactId>
- <version>${jsp-api.version}</version>
- <scope>provided</scope>
- </dependency>
- <!-- 3.jstl -->
- <dependency>
- <groupId>javax.servlet</groupId>
- <artifactId>jstl</artifactId>
- <version>${jstl.version}</version>
- <scope>runtime</scope>
- </dependency>
- <dependency>
- <groupId>taglibs</groupId>
- <artifactId>standard</artifactId>
- <version>${standard.version}</version>
- </dependency>
- <!-- 4.spring-mvc -->
- <dependency>
- <groupId>org.springframework</groupId>
- <artifactId>spring-webmvc</artifactId>
- <version>${spring-framework.version}</version>
- </dependency>
- <!-- 5.Echart-java -->
- <dependency>
- <groupId>com.github.abel533</groupId>
- <artifactId>ECharts</artifactId>
- <version>${ECharts.version}</version>
- </dependency>
- <!-- 6.Freemarker -->
- <dependency>
- <groupId>freemarker</groupId>
- <artifactId>freemarker</artifactId>
- <version>${freemarker.version}</version>
- </dependency>
- <!-- 7.Json -->
- <dependency>
- <groupId>org.codehaus.jackson</groupId>
- <artifactId>jackson-mapper-asl</artifactId>
- <version>${jackson.version}</version>
- </dependency>
- <dependency>
- <groupId>com.fasterxml.jackson.core</groupId>
- <artifactId>jackson-databind</artifactId>
- <version>${jackson-databind.version}</version>
- </dependency>
- <!-- Spring and Transactions -->
- <dependency>
- <groupId>org.springframework</groupId>
- <artifactId>spring-context</artifactId>
- <version>${spring-framework.version}</version>
- </dependency>
- <dependency>
- <groupId>org.springframework</groupId>
- <artifactId>spring-jdbc</artifactId>
- <version>${spring-framework.version}</version>
- </dependency>
- <dependency>
- <groupId>org.springframework</groupId>
- <artifactId>spring-tx</artifactId>
- <version>${spring-framework.version}</version>
- </dependency>
- <dependency>
- <groupId>org.springframework</groupId>
- <artifactId>spring-aop</artifactId>
- <version>${spring-framework.version}</version>
- </dependency>
- <dependency>
- <groupId>org.aspectj</groupId>
- <artifactId>aspectjweaver</artifactId>
- <version>${aspectjweaver.version}</version>
- </dependency>
- <!-- 文本处理 -->
- <!-- 1.Dom4j -->
- <dependency>
- <groupId>dom4j</groupId>
- <artifactId>dom4j</artifactId>
- <version>${dom4j.version}</version>
- </dependency>
- <dependency>
- <groupId>org.springframework</groupId>
- <artifactId>spring-oxm</artifactId>
- <version>${spring-framework.version}</version>
- <exclusions>
- <exclusion>
- <groupId>commons-lang</groupId>
- <artifactId>commons-lang</artifactId>
- </exclusion>
- </exclusions>
- </dependency>
- <!-- 2.Poi -->
- <dependency>
- <groupId>org.apache.poi</groupId>
- <artifactId>poi</artifactId>
- <version>${poi.version}</version>
- </dependency>
- <!-- 3.IText -->
- <dependency>
- <groupId>com.itextpdf</groupId>
- <artifactId>itextpdf</artifactId>
- <version>${itext.version}</version>
- </dependency>
- <!-- 数据库开发 -->
- <!-- 1.数据库连接池 -->
- <dependency>
- <groupId>org.apache.tomcat</groupId>
- <artifactId>tomcat-jdbc</artifactId>
- <version>${tomcat-jdbc.version}</version>
- <scope>runtime</scope>
- </dependency>
- <!-- 2.mybatis -->
- <dependency>
- <groupId>org.mybatis</groupId>
- <artifactId>mybatis</artifactId>
- <version>${mybatis.version}</version>
- </dependency>
- <!-- 3.mybatis分页插件 -->
- <dependency>
- <groupId>com.github.miemiedev</groupId>
- <artifactId>mybatis-paginator</artifactId>
- <version>${mybatis-paginator.version}</version>
- </dependency>
- <!-- 4.mybatis与spring集成 -->
- <dependency>
- <groupId>org.mybatis</groupId>
- <artifactId>mybatis-spring</artifactId>
- <version>${mybatis-spring.version}</version>
- </dependency>
- <!-- 5.Mysql 数据库驱动 -->
- <dependency>
- <groupId>mysql</groupId>
- <artifactId>mysql-connector-java</artifactId>
- <version>${mysql-connector.version}</version>
- </dependency>
- <!-- Quartz -->
- <dependency>
- <groupId>org.quartz-scheduler</groupId>
- <artifactId>quartz</artifactId>
- <version>${quartz.version}</version>
- </dependency>
- <!-- CAS -->
- <dependency>
- <groupId>org.jasig.cas.client</groupId>
- <artifactId>cas-client-core</artifactId>
- <version>${cas_client.version}</version>
- </dependency>
- <!-- Activiti -->
- <dependency>
- <groupId>org.activiti</groupId>
- <artifactId>activiti-engine</artifactId>
- <version>${activiti.version}</version>
- </dependency>
- <dependency>
- <groupId>org.activiti</groupId>
- <artifactId>activiti-spring</artifactId>
- <version>${activiti.version}</version>
- </dependency>
- <!-- 日志工具 -->
- <dependency>
- <groupId>org.slf4j</groupId>
- <artifactId>slf4j-api</artifactId>
- <version>${slf4j.version}</version>
- </dependency>
- <dependency>
- <groupId>org.apache.logging.log4j</groupId>
- <artifactId>log4j-slf4j-impl</artifactId>
- <version>${log4j.version}</version>
- </dependency>
- <dependency>
- <groupId>org.apache.logging.log4j</groupId>
- <artifactId>log4j-core</artifactId>
- <version>${log4j.version}</version>
- <scope>runtime</scope>
- </dependency>
- <dependency>
- <groupId>org.apache.logging.log4j</groupId>
- <artifactId>log4j-web</artifactId>
- <version>${log4j.version}</version>
- <scope>runtime</scope>
- </dependency>
- <!-- Test Artifacts -->
- <dependency>
- <groupId>org.springframework</groupId>
- <artifactId>spring-test</artifactId>
- <version>${spring-framework.version}</version>
- <scope>test</scope>
- </dependency>
- <dependency>
- <groupId>junit</groupId>
- <artifactId>junit</artifactId>
- <version>${junit.version}</version>
- <scope>test</scope>
- </dependency>
- <!-- 后台验证工具 -->
- <dependency>
- <groupId>org.hibernate</groupId>
- <artifactId>hibernate-validator</artifactId>
- <version>${hibernate-validator.version}</version>
- </dependency>
- <!-- 上传附件工具 -->
- <dependency>
- <groupId>commons-fileupload</groupId>
- <artifactId>commons-fileupload</artifactId>
- <version>${commons-fileupload.version}</version>
- </dependency>
- <!-- 润乾报表工具 -->
- <dependency>
- <groupId>com.runqian</groupId>
- <artifactId>ruanqian_report</artifactId>
- <version>${runqian.version}</version>
- <type>pom</type>
- </dependency>
- <!-- 1.ckeditor -->
- <dependency>
- <groupId>org.webjars</groupId>
- <artifactId>ckeditor</artifactId>
- <version>${ckeditor.version}</version>
- </dependency>
- <!-- 2.bootstrap -->
- <dependency>
- <groupId>org.webjars</groupId>
- <artifactId>bootstrap</artifactId>
- <version>${bootstrap.version}</version>
- </dependency>
- <!-- 3.echarts -->
- <dependency>
- <groupId>org.webjars</groupId>
- <artifactId>echarts</artifactId>
- <version>${echarts.version}</version>
- </dependency>
- <!-- 4.jquery -->
- <dependency>
- <groupId>org.webjars</groupId>
- <artifactId>jquery</artifactId>
- <version>${jquery.version}</version>
- </dependency>
- <!-- 5.jqwidgets -->
- <dependency>
- <groupId>org.webjars</groupId>
- <artifactId>jqwidgets</artifactId>
- <version>${jqwidgets.version}</version>
- </dependency>
- <dependency>
- <groupId>org.webjars</groupId>
- <artifactId>jquery-ui</artifactId>
- <version>${jquery-ui.version}</version>
- </dependency>
- <dependency>
- <groupId>org.webjars</groupId>
- <artifactId>jquery-form</artifactId>
- <version>${jquery-form.version}</version>
- </dependency>
- <dependency>
- <groupId>org.webjars</groupId>
- <artifactId>jquery.validate.js</artifactId>
- <version>${jquery.validate.js.version}</version>
- </dependency>
- <!-- 文件操作工具 -->
- <dependency>
- <groupId>org.webjars</groupId>
- <artifactId>jquery-file-upload</artifactId>
- <version>${jquery-file-upload.version}</version>
- </dependency>
- </dependencies>
- </dependencyManagement>
- <build>
- <pluginManagement>
- <plugins>
- <plugin>
- <artifactId>maven-eclipse-plugin</artifactId>
- <version>2.9</version>
- <configuration>
- <additionalProjectnatures>
- <projectnature>org.springframework.ide.eclipse.core.springnature</projectnature>
- </additionalProjectnatures>
- <additionalBuildcommands>
- <buildcommand>org.springframework.ide.eclipse.core.springbuilder</buildcommand>
- </additionalBuildcommands>
- <downloadSources>true</downloadSources>
- <downloadJavadocs>true</downloadJavadocs>
- </configuration>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-compiler-plugin</artifactId>
- <version>2.5.1</version>
- <configuration>
- <source>${jdk.version}</source>
- <target>${jdk.version}</target>
- <showWarnings>true</showWarnings>
- <showDeprecation>true</showDeprecation>
- <encoding>UTF-8</encoding>
- </configuration>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-resources-plugin</artifactId>
- <version>2.7</version>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-surefire-plugin</artifactId>
- <version>2.18.1</version>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-failsafe-plugin</artifactId>
- <version>2.18.1</version>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-verifier-plugin</artifactId>
- <version>1.0</version>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-source-plugin</artifactId>
- <version>2.4</version>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-javadoc-plugin</artifactId>
- <version>2.10.1</version>
- </plugin>
- <plugin>
- <groupId>org.mybatis.generator</groupId>
- <artifactId>mybatis-generator-maven-plugin</artifactId>
- <version>1.3.0</version>
- <configuration>
- <verbose>true</verbose>
- <overwrite>true</overwrite>
- </configuration>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-surefire-report-plugin</artifactId>
- <version>2.18.1</version>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-assembly-plugin</artifactId>
- <version>2.5.3</version>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-dependency-plugin</artifactId>
- <version>2.10</version>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-enforcer-plugin</artifactId>
- <version>1.4</version>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-release-plugin</artifactId>
- <version>2.5.1</version>
- </plugin>
- <plugin>
- <groupId>org.codehaus.cargo</groupId>
- <artifactId>cargo-maven2-plugin</artifactId>
- <version>1.4.12</version>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-checkstyle-plugin</artifactId>
- <version>2.14</version>
- <dependencies>
- <dependency>
- <groupId>com.puppycrawl.tools</groupId>
- <artifactId>checkstyle</artifactId>
- <version>6.0</version>
- </dependency>
- </dependencies>
- <configuration>
- <encoding>UTF-8</encoding>
- </configuration>
- </plugin>
- <plugin>
- <groupId>org.codehaus.mojo</groupId>
- <artifactId>findbugs-maven-plugin</artifactId>
- <version>3.0.0</version>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-scm-plugin</artifactId>
- <version>1.9.2</version>
- </plugin>
- <plugin>
- <groupId>org.codehaus.mojo</groupId>
- <artifactId>exec-maven-plugin</artifactId>
- <version>1.2.1</version>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-jar-plugin</artifactId>
- <version>2.5</version>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-war-plugin</artifactId>
- <version>2.6</version>
- </plugin>
- <plugin>
- <groupId>org.apache.tomcat.maven</groupId>
- <artifactId>tomcat7-maven-plugin</artifactId>
- <version>2.2</version>
- <configuration>
- <charset>UTF-8</charset>
- </configuration>
- </plugin>
- </plugins>
- </pluginManagement>
- </build>
- <repositories>
- <repository>
- <id>micaicms</id>
- <name>Micaicms Repositories</name>
- <url>http://127.0.0.1:8081/nexus/content/groups/public/</url>
- <releases>
- <enabled>true</enabled>
- </releases>
- <snapshots>
- <enabled>true</enabled>
- </snapshots>
- </repository>
- </repositories>
- <pluginRepositories>
- <pluginRepository>
- <id>Micaicms</id>
- <name>Micaicms Plugin Repositories</name>
- <url>http://127.0.0.1:8081/nexus/content/groups/public/</url>
- <releases>
- <enabled>true</enabled>
- </releases>
- <snapshots>
- <enabled>true</enabled>
- </snapshots>
- </pluginRepository>
- </pluginRepositories>
- <distributionManagement>
- <repository>
- <id>releases</id>
- <name>Micaicms Releases</name>
- <url>http://127.0.0.1:8081/nexus/content/repositories/releases/</url>
- </repository>
- <snapshotRepository>
- <id>snapshots</id>
- <name>Micaicms Releases</name>
- <url>http://127.0.0.1:8081/nexus/content/repositories/snapshots/</url>
- </snapshotRepository>
- </distributionManagement>
- </project>
二:micaicms-pom项目的源码地址:micaicms-pom
Maven之自定义pom类型的基础项目的更多相关文章
- maven 构建spring boot + mysql 的基础项目
一.maven 依赖 <parent> <groupId>org.springframework.boot</groupId> <artifactId> ...
- Maven之自定义archetype生成项目骨架(一)
Maven之自定义archetype生成项目骨架(一) 标签: mavennexus插件 2015-07-15 16:40 2443人阅读 评论(0) 收藏 举报 分类: Maven技术(9) ...
- (转)Maven之自定义archetype生成项目骨架
背景:最近在开发一个项目的基础构件,在以后项目的开发过程中可以直接使用该构件快速的生成项目骨架进行开发. 摘要:使用过Maven的人都知道maven中有许多功能都是通过插件来提供的,今天我们来说一下其 ...
- Java归去来第4集:java实战之Eclipse中创建Maven类型的SSM项目
一.前言 如果还不了解剧情,请返回第3集的剧情 Java归去来第3集:Eclipse中给动态模块升级 二.在Eclipse中创建Maven类型的SSM项目 2.1:SSM简介 SSM ...
- Maven之自定义archetype生成项目骨架
Maven之自定义archetype生成项目骨架(一) http://blog.csdn.net/sxdtzhaoxinguo/article/details/46895013
- maven自定义脚手架(快速生成项目)
Maven之自定义archetype生成项目骨架 利用脚手架生成 新项目 命令行方式 mvn archetype:generate \ -DarchetypeGroupId=com.xxx \ -Da ...
- 【原】无脑操作:IDEA + maven + Shiro + SpringBoot + JPA + Thymeleaf实现基础授权权限
上一篇<[原]无脑操作:IDEA + maven + Shiro + SpringBoot + JPA + Thymeleaf实现基础认证权限>介绍了实现Shiro的基础认证.本篇谈谈实现 ...
- maven核心,pom.xml详解(转)
什么是pom? pom作为项目对象模型.通过xml表示maven项目,使用pom.xml来实现.主要描述了项目:包括配置文件:开发者需要遵循的规则,缺陷管理系统,组织和licenses,项目的u ...
- 【转】maven核心,pom.xml详解
感谢如下博主: http://www.cnblogs.com/qq78292959/p/3711501.html maven核心,pom.xml详解 什么是pom? pom作为项目对象模型.通过 ...
随机推荐
- Convolutional Neural Networks(5):Pooling Layer
池化层(Pooling layer)同样是收到了视觉神经科学的启发.在初级视觉皮层V1(Primary visual cortex)中,包含了许多复杂细胞(Complex cells),这些细胞对于图 ...
- 远控CVE整理
Windows: CVE-2017-8464(通过快捷方式,可U盘/共享等途径传播)
- HTML5-新增type属性
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8&quo ...
- Linux 安装jdk+mysql+tomcat
参考: 安装 jdk+mysql+tomcat https://www.w3h5.com/post/65.html 安装 mysql https://blog.csdn.net/qq_23123 ...
- MySQL-第九篇分组和组函数
1.组函数 组函数:即多行函数,组函数将一组记录作为整体计算,每组记录返回一个结果,而不是每条记录返回一个结果. 2.常用的组函数有: 1>avg([distinct|all]expr):计算多 ...
- noip2018考后反思之爆0
今年又被Han老师鞭尸了TAT noip普及组比齐同学考的都差,正在准备退役Orz 哎,算了,该放题解还是要放的:( 普及第一题我觉得没有放的必要还是放一下 Code: #include<ios ...
- 洛谷 P1049 装箱问题(01背包)
一道水题,但看到好久没有发博客了,再一看是一道noip普及组t4,就做了. 题目链接 https://www.luogu.org/problemnew/show/P1049 解题思路 一道裸的01背包 ...
- python小学堂1
sun=0 start=1 while True: start1=start%2 if start1==1: sun = start + sun elif start1==0: sun=sun-sta ...
- seaborn教程4——分类数据可视化
https://segmentfault.com/a/1190000015310299 Seaborn学习大纲 seaborn的学习内容主要包含以下几个部分: 风格管理 绘图风格设置 颜色风格设置 绘 ...
- 1-for循环套生成器的面试题
参考自: https://www.cnblogs.com/shuimohei/p/9686578.html https://segmentfault.com/a/1190000016577353 题目 ...