add publishing to github packages

master
bvn13 2022-01-29 01:26:15 +03:00
parent 857ce637a7
commit e0fe404832
1 changed files with 19 additions and 0 deletions

View File

@ -1,6 +1,7 @@
plugins {
id 'java'
id 'idea'
id 'maven-publish'
}
group 'me.bvn13'
@ -34,4 +35,22 @@ test {
tasks.withType(Test).configureEach {
maxParallelForks = 1
}
publishing {
repositories {
maven {
name = "GitHubPackages"
url = uri("https://maven.pkg.github.com/bvn13/sewy")
credentials {
username = project.findProperty("gpr.user") ?: System.getenv("USERNAME")
password = project.findProperty("gpr.key") ?: System.getenv("TOKEN")
}
}
}
publications {
gpr(MavenPublication) {
from(components.java)
}
}
}