-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'SDK-1196-mavencentral' into 'develop'
migrate publication from jcenter to mavencentral Closes SDK-1196 See merge request sdk_group/store-android-sdk!68
- Loading branch information
Showing
20 changed files
with
176 additions
and
551 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,96 @@ | ||
apply plugin: 'maven-publish' | ||
apply plugin: 'signing' | ||
|
||
task androidSourcesJar(type: Jar) { | ||
archiveClassifier.set('sources') | ||
from android.sourceSets.main.java.srcDirs | ||
from android.sourceSets.main.kotlin.srcDirs | ||
} | ||
|
||
artifacts { | ||
archives androidSourcesJar | ||
} | ||
|
||
group = PUBLISH_GROUP_ID | ||
version = PUBLISH_VERSION | ||
|
||
ext["signing.keyId"] = '' | ||
ext["signing.password"] = '' | ||
ext["signing.secretKeyRingFile"] = '' | ||
ext["ossrhUsername"] = '' | ||
ext["ossrhPassword"] = '' | ||
|
||
File localPropertiesFile = project.rootProject.file('local.properties') | ||
if (localPropertiesFile.exists()) { | ||
Properties properties = new Properties() | ||
properties.load(new FileInputStream(localPropertiesFile)) | ||
properties.each { name, value -> | ||
ext[name] = value | ||
} | ||
} else { | ||
ext["signing.keyId"] = System.getenv('SIGNING_KEY_ID') | ||
ext["signing.password"] = System.getenv('SIGNING_PASSWORD') | ||
ext["signing.secretKeyRingFile"] = System.getenv('SIGNING_SECRET_KEY_RING_FILE') | ||
ext["ossrhUsername"] = System.getenv('OSSRH_USERNAME') | ||
ext["ossrhPassword"] = System.getenv('OSSRH_PASSWORD') | ||
} | ||
|
||
publishing { | ||
publications { | ||
release(MavenPublication) { | ||
groupId PUBLISH_GROUP_ID | ||
artifactId PUBLISH_ARTIFACT_ID | ||
version PUBLISH_VERSION | ||
|
||
artifact("$buildDir/outputs/aar/${project.getName()}-release.aar") | ||
|
||
artifact androidSourcesJar | ||
|
||
pom { | ||
name = PUBLISH_NAME | ||
description = PUBLISH_DESCRIPTION | ||
url = 'https://github.com/xsolla/store-android-sdk' | ||
organization { | ||
name = 'Xsolla' | ||
url = 'https://xsolla.com' | ||
} | ||
licenses { | ||
license { | ||
name = 'The Apache Software License, Version 2.0' | ||
url = 'http://www.apache.org/licenses/LICENSE-2.0.txt' | ||
} | ||
} | ||
scm { | ||
connection = 'https://github.com/xsolla/store-android-sdk.git' | ||
developerConnection = 'https://github.com/xsolla/store-android-sdk.git' | ||
url = 'https://github.com/xsolla/store-android-sdk.git' | ||
} | ||
withXml { | ||
def dependenciesNode = asNode().appendNode('dependencies') | ||
|
||
project.configurations.implementation.allDependencies.each { | ||
def dependencyNode = dependenciesNode.appendNode('dependency') | ||
dependencyNode.appendNode('groupId', it.group) | ||
dependencyNode.appendNode('artifactId', it.name) | ||
dependencyNode.appendNode('version', it.version) | ||
} | ||
} | ||
} | ||
} | ||
} | ||
repositories { | ||
maven { | ||
name = "sonatype" | ||
url = "https://oss.sonatype.org/service/local/staging/deploy/maven2/" | ||
|
||
credentials { | ||
username ossrhUsername | ||
password ossrhPassword | ||
} | ||
} | ||
} | ||
} | ||
|
||
signing { | ||
sign publishing.publications | ||
} |
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 was deleted.
Oops, something went wrong.
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 was deleted.
Oops, something went wrong.
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 was deleted.
Oops, something went wrong.
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
Oops, something went wrong.