首页 > 其他分享 >jar包冲突,修改jar包的路径

jar包冲突,修改jar包的路径

时间:2023-06-21 11:47:08浏览次数:44  
标签:路径 jar maven 冲突 poi apache org com

<?xml version="1.0" encoding="UTF-8"?>

<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.example</groupId>
<artifactId>wordTemplate</artifactId>
<version>1.0-SNAPSHOT</version>

<name>pagejar2</name>
<!-- FIXME change it to the project's website -->
<url>http://www.example.com</url>

<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<maven.compiler.source>1.7</maven.compiler.source>
<maven.compiler.target>1.7</maven.compiler.target>
</properties>

<dependencies>
<!-- https://mvnrepository.com/artifact/org.apache.poi/poi -->
<dependency>
<groupId>org.apache.poi</groupId>
<artifactId>poi</artifactId>
<version>3.16</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.apache.poi/poi-ooxml -->
<dependency>
<groupId>org.apache.poi</groupId>
<artifactId>poi-ooxml</artifactId>
<version>3.16</version>
</dependency>
<!-- https://mvnrepository.com/artifact/com.deepoove/poi-tl -->
<dependency>
<groupId>com.deepoove</groupId>
<artifactId>poi-tl</artifactId>
<version>1.5.1</version>
</dependency>


</dependencies>

<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-shade-plugin</artifactId>
<version>3.2.4</version>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>shade</goal>
</goals>
<configuration>
<createDependencyReducedPom>true</createDependencyReducedPom>
<relocations>
<relocation>
<!-- 改名前 -->
<pattern>org.apache.poi</pattern>
<!-- 改名后 -->
<shadedPattern>shaded.org.apache.poi</shadedPattern>
</relocation>

可以配置多个
<relocation>
<!-- 改名前 -->
<pattern>com.deepoove.poi</pattern>
<!-- 改名后 -->
<shadedPattern>shaded.com.deepoove.poi</shadedPattern>
</relocation>
</relocations>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>

标签:路径,jar,maven,冲突,poi,apache,org,com
From: https://www.cnblogs.com/doumenwangjian/p/17495864.html

相关文章

  • 由JAVA环境变量Classpath与logging.config配置冲突的异常:
     Classpath与logging.config配置冲突异常信息:     ......
  • svg clipPath的clipPathUnits和相对路径转换
    clipPathUnits属性用来指定<clipPath>元素内容的坐标系,有2种取值:clipPathUnits="userSpaceOnUse|objectBoundingBox"clipPathUnits="userSpaceOnUse|objectBoundingBox"userSpaceOnUse表示当前网页所使用的屏幕坐标系objectBoundingBox则把坐标空间的原点调整到被......
  • 6-3 最短路径(弗洛伊德算法)
    #include<iostream>usingnamespacestd;#defineMaxInt32767#defineMVNum100typedefcharVerTexType;typedefintArcType;intPath[MVNum][MVNum];//标志两个结点之间是否可达intD[MVNum][MVNum];//存储两个结点间的边的权重typedefstruct{VerTexT......
  • 6.20 git的分支 远程仓库 多人协同 冲突解决
    1.git多分支应用 >1 查看分支gitbranch (只看本地)gitbranch-a (查看所有分支,可以看本地和远程)>2  创建分支gitbranch dev>3 切换分支gitcheckout 分支名字>4 删除分支gitbranch-d分支名>5 合并分支的操作/1  git......
  • git 多分支,git远程仓库,ssh方式链接远程仓库,协同开发,冲突解决
    目录一、git多分支二、git远程仓库修改用户名username三、ssh方式链接远程仓库具体操作-1先删除原来使用https链接的remote-2增加一个跟远程仓库的链接origin---》是ssh协议的-3本地机器,生成公钥私钥[使用命令生成]-4把公钥配置在gitee上【打开公钥】--》可以配多个-5以......
  • 05 git 多分支,远程仓库,ssh方式链接远程仓库,协同开发,冲突解决
    1git多分支#分支操作0查看分支gitbranch#本地gitbranch-a#本地和远程1创建分支gitbranchdev2切换分支gitcheckout分支名字3删除分支gitbranch-d分支名4合并分支操作步骤 gitbranchdevgitcheckoutdev#dev分支操作......
  • 路径计数 6.20西安集训(最短哈密顿回路条数)
     因为是哈密顿回路,所以每个点度数为2假设我们已经考虑了i个点,其中b个B,w个W。若存在x条由{1,2,...n}连向{i+1,...2n},那么{1...n}内部的连边数为(2*i-x)/2而只有不同颜色的点会连边,故(2*i-x)/2<=2*min(w,b)x>=2(w+b)-4min(w,b)=2|w-b|则x>=2max(1,|w-b|).为了求得最短路,我们肯定......
  • 【HarmonyOS】如何解决智能穿戴设备中swiper组件右滑与系统退出应用冲突问题(API6 JS)
    【关键字】API6、JS、swiper组件、智能穿戴、setSwipeToDismiss【问题描述】使用API6JS开发智能穿戴设备HarmonyOS应用,在首页使用swiper组件时,右滑swiper时会退出应用,无法实现swiper右滑效果,效果如下所示:【问题分析与原因】当页面栈只有一个页面时,默认滑动事件分发会让应用退出,而......
  • 20230410 11.3. 冲突处理方法
    处理冲突的方法开放地址法:换个位置链地址法:同一位置的冲突对象组织在一起散列表查找性能分析成功平均查找长度(ASLs)不成功平均查找长度(ASLu)开放定址法(OpenAddressing)一旦产生了冲突(该地址已有其它元素),就按某种规则去寻找另一空地址若发生了第i次冲突,试探的下一......
  • P3371 【模板】单源最短路径(弱化版)(C++_SPFA算法_链式向前星)
    题目背景本题测试数据为随机数据,在考试中可能会出现构造数据让SPFA不通过,如有需要请移步P4779。题目描述如题,给出一个有向图,请输出从某一点出发到所有点的最短路径长度。输入格式第一行包含三个整数n,m,s,分别表示点的个数、有向边的个数、出发点的编号。接下来m行每行包含三个......