maven-demo

部署到maven中央仓库示例

License

License

Categories

Categories

Maven Build Tools
GroupId

GroupId

com.github.itcrazy2008
ArtifactId

ArtifactId

maven-demo
Last Version

Last Version

1.0.4
Release Date

Release Date

Type

Type

jar
Description

Description

maven-demo
部署到maven中央仓库示例
Project URL

Project URL

https://github.com/itcrazy2008
Source Code Management

Source Code Management

https://github.com/itcrazy2008/maven-demo

Download maven-demo

How to add to project

<!-- https://jarcasting.com/artifacts/com.github.itcrazy2008/maven-demo/ -->
<dependency>
    <groupId>com.github.itcrazy2008</groupId>
    <artifactId>maven-demo</artifactId>
    <version>1.0.4</version>
</dependency>
// https://jarcasting.com/artifacts/com.github.itcrazy2008/maven-demo/
implementation 'com.github.itcrazy2008:maven-demo:1.0.4'
// https://jarcasting.com/artifacts/com.github.itcrazy2008/maven-demo/
implementation ("com.github.itcrazy2008:maven-demo:1.0.4")
'com.github.itcrazy2008:maven-demo:jar:1.0.4'
<dependency org="com.github.itcrazy2008" name="maven-demo" rev="1.0.4">
  <artifact name="maven-demo" type="jar" />
</dependency>
@Grapes(
@Grab(group='com.github.itcrazy2008', module='maven-demo', version='1.0.4')
)
libraryDependencies += "com.github.itcrazy2008" % "maven-demo" % "1.0.4"
[com.github.itcrazy2008/maven-demo "1.0.4"]

Dependencies

There are no dependencies for this project. It is a standalone project that does not depend on any other jars.

Project Modules

There are no modules declared in this project.

将代码部署到maven中央仓库示例

  • https://blog.csdn.net/a979331856/article/details/89498455
  • 关键的步骤如下:
    • sonatype申请账号
    • 在JIRA上创建 Issue,等待审核
    • 下载 Gpg4win 软件,处理GPG信息,生成并发布公钥(注意公钥ID 可能是16位的比较准,8位的对吗?)
    • 新建项目,注意pom.xml文件,非常严格,下载maven的各插件
    • 配置本地的全局的settings.xml,和pom.xml中的id对应起来
    • 提交项目代码到oss
    • 然后在oss上close和release,成功后过2个小时,就可以在maven中央仓库查询到自己提交的代码并通过dependencies引用
    • 通知工作人员关闭Issue

Versions

Version
1.0.4