元数据

每个目录的存储库元数据repository-metadata.xml。

一个目录可以表示 3 种类型的内容:“groupId”、“groupId/artifactId”或“groupId/artifactId/version”。

大多数元数据内容在目录代表“groupId/artifactId”( groupId, artifactId, versioning)时有意义

<metadata xmlns="http://maven.apache.org/METADATA/1.1.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  xsi:schemaLocation="http://maven.apache.org/METADATA/1.1.0 https://maven.apache.org/xsd/repository-metadata-1.1.0.xsd"
  modelVersion=.. >
  <groupId/>
  <artifactId/>
  <versioning>
    <latest/>
    <release/>
    <versions/>

    <lastUpdated/>

    <snapshot>
      <timestamp/>
      <buildNumber/>
      <localCopy/>
    </snapshot>
    <snapshotVersions>
      <snapshotVersion>
        <classifier/>
        <extension/>
        <value/>
        <updated/>
      </snapshotVersion>
    </snapshotVersions>
  </versioning>
  <version/>

  <plugins>
    <plugin>
      <name/>
      <prefix/>
      <artifactId/>
    </plugin>
  </plugins>
</metadata>

元数据

没有说明。

属性 类型 描述
modelVersion String 底层元数据模型的版本。
元素 类型 描述
groupId String 该目录表示“groupId/artifactId”或“groupId/artifactId/version”时的groupId。
artifactId String 此目录表示“groupId/artifactId”或“groupId/artifactId/version”时的artifactId。
versioning Versioning 此目录表示“groupId/artifactId”或“groupId/artifactId/version”时的版本控制信息。
version String -SNAPSHOT当此目录表示 SNAPSHOT 的“groupId/artifactId/version”时的基本版本(即以 结尾 )。
plugins/plugin* List<Plugin> (许多)此目录表示“groupId”时的插件集(已弃用)

版本控制

“groupId/artifactId”或“groupId/artifactId/version”SNAPSHOT 的版本信息

元素 类型 描述
latest String 添加到目录的最后一个版本是什么,包括版本和快照(仅“groupId/artifactId”目录)
release String 添加到目录的最后一个版本是什么,仅适用于发行版(仅“groupId/artifactId”目录)
versions/version* List<String> (许多)工件的可用版本(发行版和快照)(仅限“groupId/artifactId”目录)
lastUpdated String 上次更新元数据的时间(“groupId/artifactId”和“groupId/artifactId/version”目录)。时间戳以 yyyyMMddHHmmss 格式使用 UTC 表示。
snapshot Snapshot 此版本使用的当前快照数据(仅限“groupId/artifactId/version”)
snapshotVersions/snapshotVersion* List<SnapshotVersion> (许多)此工件快照中可用的每个子工件的信息。这只是每个唯一扩展/分类器组合的最新 SNAPSHOT。

快照

对应于 SNAPSHOT 基本版本的最后一个工件的快照数据

元素 类型 描述
timestamp String 部署此版本时的时间戳。时间戳以 yyyyMMdd.HHmmss 格式使用 UTC 表示。
buildNumber int 增量内部版本号
默认值为: 0。
localCopy boolean 是否改为使用本地副本(文件名包含基本版本)
默认值为: false。

快照版本

当前快照工件的子工件的版本控制信息。

元素 类型 描述
classifier String 子工件的分类器。每个分类器和扩展对只能出现一次。
默认值为:。
extension String 子工件的文件扩展名。每个分类器和扩展对只能出现一次。
value String 子工件的已解析快照版本。
updated String 上次更新此版本信息时的时间戳。时间戳以 yyyyMMddHHmmss 格式使用 UTC 表示。

插入

此组中单个插件的映射信息(已弃用)。

元素 类型 描述
name String 插件的显示名称。
prefix String 插件调用前缀(即eclipse for eclipse:eclipse)
artifactId String 插件 artifactId