-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: Add the ability to publish to Github packages
Signed-off-by: Avior <[email protected]>
- Loading branch information
1 parent
238c215
commit 7c7ca17
Showing
3 changed files
with
61 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -85,5 +85,45 @@ publishing { | |
} | ||
} | ||
} | ||
register<MavenPublication>("gpr") { | ||
// groupId = group | ||
artifactId = artifact | ||
// version = ver | ||
|
||
from(components["java"]) | ||
|
||
pom { | ||
name.set("TCGdex SDK") | ||
description.set("Communicate with the Open Source TCGdex API in Kotlin/Java using the SDK") | ||
url.set("https://github.com/tcgdex/java-sdk") | ||
licenses { | ||
license { | ||
name.set("MIT License") | ||
url.set("https://github.com/tcgdex/java-sdk/blob/master/LICENSE.txt") | ||
} | ||
} | ||
developers { | ||
developer { | ||
id.set("avior") | ||
name.set("Avior") | ||
email.set("[email protected]") | ||
} | ||
} | ||
scm { | ||
connection.set("scm:[email protected]:tcgdex/java-sdk.git") | ||
url.set("https://github.com/tcgdex/java-sdk") | ||
} | ||
} | ||
} | ||
} | ||
repositories { | ||
maven { | ||
name = "GithubPackages" | ||
url = uri("https://maven.pkg.github.com/tcgdex/java-sdk") | ||
credentials { | ||
username = project.findProperty("gpr.user") as String? ?: System.getenv("USERNAME") | ||
password = project.findProperty("gpr.key") as String? ?: System.getenv("TOKEN") | ||
} | ||
} | ||
} | ||
} |