zoukankan      html  css  js  c++  java
  • 将本地jar包手动复制到Maven库中,在其它电脑上用Maven打包时出错

    版权声明:本文为博主原创文章,未经博主同意不得转载。 https://blog.csdn.net/UP19910522/article/details/31396107

    背景交代:在做图片水印时候引入了两个包文件。这两个包是JDK自带的私有包,不能用Maven库里下载,因此笔者手动将rt和jce两个工具jar文件复制到本地的Maven库中。例如以下图


    import com.sun.image.codec.jpeg.JPEGCodec;
    import com.sun.image.codec.jpeg.JPEGImageEncoder;
    然后在pom配置文件中写上以下的配置

    将jce和rt拷到例如以下路径(rt相似)


    然后项目在其它电脑上用Maven打包时候报错例如以下:

    Failed to execute goal on project : Could not resolve dependencies for project cs2c.nkscloudweb:nkscloudweb3:war:3.0: The following artifacts could not be resolved: maven-plugins:maven-cobertura-plugin:plugin:1.3, maven-plugins:maven-findbugs-plugin:plugin:1.3.1: Could not find artifact maven-plugins:maven-cobertura-plugin:plugin:1.3 in nexus (http://10.1.81.221:8081/nexus/content/groups/public) -> [Help 

    最后的解决方法是:在他的计算机上配置例如以下路径:

    <dependency>
                <groupId>rt</groupId>
                <artifactId>rt</artifactId>
                <version>1.0</version>
    <systemPath>D:maven
    epositories
    t
    t1.0
    t-1.0.jar</systemPath>
     </dependency> 

    
    
    
    
    

查看全文
  • 相关阅读:
    再谈TextField
    IOS-TextField知多少
    leftBarButtonItems
    LeftBarButtonItems,定制导航栏返回按钮
    Apple Mach-O Linker (id) Error "_OBJC_CLASS...错误解决办法 Apple Mach-O Linker (id) Error "_OBJC_CLASS...错误解决办法
    Unrecognized Selector Sent to Instance问题之诱敌深入关门打狗解决办法
    UNRECOGNIZED SELECTOR SENT TO INSTANCE 问题快速定位的方法
    Present ViewController,模态详解
    UILABEL AUTOLAYOUT自动换行 版本区别
    iOS自动布局解决警告Automatic Preferred Max Layout Width is not available on iOS versions prior to 8.0
  • 原文地址:https://www.cnblogs.com/ldxsuanfa/p/10818675.html
  • Copyright © 2011-2022 走看看