This repository has been archived on 2023-02-13. You can view files and clone it, but cannot push or open issues or pull requests.
KN4CK3R 47d0ef17fb Update maven deploy docs (#20691)
Co-authored-by: Lunny Xiao <>
2022-08-07 21:58:03 +08:00

2.8 KiB

date title slug draft toc menu
2021-07-20T00:00:00+00:00 Maven Packages Repository packages/maven false false
parent name weight identifier
packages Maven 60 maven

Maven Packages Repository

Publish Maven packages for your user or organization.

Table of Contents

{{< toc >}}


To work with the Maven package registry, you can use Maven or Gradle. The following examples use Maven.

Configuring the package registry

To register the package registry you first need to add your access token to the settings.xml file:

            <value>token {access_token}</value>

Afterwards add the following sections to your project pom.xml file:

Parameter Description
access_token Your [personal access token]({{< relref "doc/developers/" >}}).
owner The owner of the package.

Publish a package

To publish a package simply run:

mvn deploy

If you want to publish a prebuild package to the registry, you can use mvn deploy:deploy-file:

mvn deploy:deploy-file -Durl={owner}/maven -DrepositoryId=gitea -Dfile=/path/to/package.jar
Parameter Description
owner The owner of the package.

You cannot publish a package if a package of the same name and version already exists. You must delete the existing package first.

Install a package

To install a Maven package from the package registry, add a new dependency to your project pom.xml file:


Afterwards run:

mvn install

Supported commands

mvn install
mvn deploy
mvn dependency:get: