zoukankan      html  css  js  c++  java
  • gradle本地文件仓库 (52.6.5. Flat directory repository)

    If you want to use a (flat) filesystem directory as a repository, simply type:


    Example 52.32. Flat repository resolver

    build.gradle

    repositories {
        flatDir {
            dirs 'lib'
        }
        flatDir {
            dirs 'lib1', 'lib2'
        }
    }
    

    This adds repositories which look into one or more directories for finding dependencies. Note that this type of repository does not support any meta-data formats like Ivy XML or Maven POM files. Instead, Gradle will dynamically generate a module descriptor (without any dependency information) based on the presence of artifacts. However, as Gradle prefers to use modules whose descriptor has been created from real meta-data rather than being generated, flat directory repositories cannot be used to override artifacts with real meta-data from other repositories. So, for example, if Gradle finds only jmxri-1.2.1.jar in a flat directory repository, but jmxri-1.2.1.pom in another repository that supports meta-data, it will use the second repository to provide the module. For the use case of overriding remote artifacts with local ones consider using an Ivy or Maven repository instead whose URL points to a local directory. If you only work with flat directory repositories you don't need to set all attributes of a dependency. See Section 52.4.8, “Optional attributes”.

    这种类型的仓库不支持 元数据 格式 如 Lvy XML,  Maven POM 文件

  • 相关阅读:
    单元测试
    python gdb
    圣诞树
    网络是怎样连接的 读书笔记
    POJ2104 K-th Number(整体二分)
    [SDOI2011]消耗战
    [HNOI2011]XOR和路径
    [HNOI2013]游走
    [JSOI2008]球形空间产生器
    POJ2728 Desert King
  • 原文地址:https://www.cnblogs.com/zhao1949/p/5672548.html
Copyright © 2011-2022 走看看