From e0e590723fc5824b52893575fae0d7223dba107a Mon Sep 17 00:00:00 2001 From: Mohamed Yousif Date: Mon, 24 Oct 2022 13:13:56 +0200 Subject: [PATCH] add github package repo --- build.gradle | 2 -- lib/build.gradle | 22 +++++++++++++++++++++- 2 files changed, 21 insertions(+), 3 deletions(-) diff --git a/build.gradle b/build.gradle index dcb3b61..e69de29 100644 --- a/build.gradle +++ b/build.gradle @@ -1,2 +0,0 @@ -// Top-level build file where you can add configuration options common to all sub-projects/modules. - diff --git a/lib/build.gradle b/lib/build.gradle index 4cac408..0964685 100644 --- a/lib/build.gradle +++ b/lib/build.gradle @@ -24,7 +24,7 @@ buildscript { apply plugin: 'kotlin' apply plugin: 'java-library' - +apply plugin: 'maven-publish' repositories { // Use JCenter for resolving dependencies. @@ -61,3 +61,23 @@ test { useJUnitPlatform() } +// Top-level build file where you can add configuration options common to all sub-projects/modules. + + +publishing { + repositories { + maven { + name = "GitHubPackages" + url = uri("https://maven.pkg.github.com/tutipay/java-sdk") + credentials { + username = project.findProperty("gpr.user") ?: System.getenv("USERNAME") + password = project.findProperty("gpr.key") ?: System.getenv("TOKEN") + } + } + } + publications { + gpr(MavenPublication) { + from(components.java) + } + } +}