build: публикация
This commit is contained in:
16
README.MD
16
README.MD
@@ -5,17 +5,11 @@
|
|||||||
### Gradle
|
### Gradle
|
||||||
|
|
||||||
```groovy
|
```groovy
|
||||||
implementation("ru.di9:xml-element:1.0")
|
repositories {
|
||||||
|
maven { url "https://di9.ru/git/api/packages/Voomra/maven" }
|
||||||
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
## Сборка
|
```groovy
|
||||||
|
implementation("ru.di9:xml-element:1.2.1")
|
||||||
```shell
|
|
||||||
gradle build
|
|
||||||
```
|
|
||||||
|
|
||||||
## Установка в локальный Maven
|
|
||||||
|
|
||||||
```shell
|
|
||||||
gradle publishToMavenLocal
|
|
||||||
```
|
```
|
||||||
|
|||||||
21
build.gradle
21
build.gradle
@@ -35,7 +35,8 @@ test {
|
|||||||
useJUnitPlatform()
|
useJUnitPlatform()
|
||||||
}
|
}
|
||||||
|
|
||||||
publishing.publications {
|
publishing {
|
||||||
|
publications {
|
||||||
mavenBinary(MavenPublication) {
|
mavenBinary(MavenPublication) {
|
||||||
groupId = project.group
|
groupId = project.group
|
||||||
artifactId = project.name
|
artifactId = project.name
|
||||||
@@ -43,4 +44,22 @@ publishing.publications {
|
|||||||
|
|
||||||
from components.java
|
from components.java
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
repositories {
|
||||||
|
maven {
|
||||||
|
name = "Di9"
|
||||||
|
url = uri("https://di9.ru/git/api/packages/Voomra/maven")
|
||||||
|
def giteaToken = System.getenv("GITEA_TOKEN")
|
||||||
|
|
||||||
|
credentials(HttpHeaderCredentials) {
|
||||||
|
name = "Authorization"
|
||||||
|
value = "token ${giteaToken}"
|
||||||
|
}
|
||||||
|
|
||||||
|
authentication {
|
||||||
|
header(HttpHeaderAuthentication)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user