From cdc4e9c8ac687ab4b2a880f4100189ec68567d00 Mon Sep 17 00:00:00 2001 From: oSumAtrIX Date: Tue, 14 Jun 2022 01:11:54 +0200 Subject: [PATCH] chore: publish releases instead of packages --- .releaserc | 14 +++++++++++--- build.gradle.kts | 50 ++++++++++++++++-------------------------------- 2 files changed, 27 insertions(+), 37 deletions(-) diff --git a/.releaserc b/.releaserc index ab20d0c..8cbf9d3 100644 --- a/.releaserc +++ b/.releaserc @@ -10,7 +10,6 @@ "@semantic-release/commit-analyzer", "@semantic-release/release-notes-generator", "@semantic-release/changelog", - "gradle-semantic-release-plugin", [ "@semantic-release/git", { @@ -20,6 +19,15 @@ ] } ], - "@semantic-release/github" + [ + "@semantic-release/github", + { + "assets": [ + { + "path": "build/libs/*.jar" + } + ] + } + ] ] -} \ No newline at end of file +} diff --git a/build.gradle.kts b/build.gradle.kts index 4a89e76..675b478 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -1,42 +1,42 @@ plugins { - kotlin("jvm") version "1.6.21" + kotlin("jvm") version "1.7.0" id("com.github.johnrengelman.shadow") version "7.1.2" - java - `maven-publish` } group = "app.revanced" +val githubUsername: String = project.findProperty("gpr.user") as? String ?: System.getenv("GITHUB_ACTOR") +val githubPassword: String = project.findProperty("gpr.key") as? String ?: System.getenv("GITHUB_TOKEN") + repositories { mavenCentral() - google() - mavenLocal() maven { url = uri("https://maven.pkg.github.com/revanced/multidexlib2") credentials { - username = project.findProperty("gpr.user") as String? ?: System.getenv("GITHUB_ACTOR") // DO NOT CHANGE! - password = project.findProperty("gpr.key") as String? ?: System.getenv("GITHUB_TOKEN") // DO NOT CHANGE! + username = githubUsername + password = githubPassword } } maven { - url = uri("https://jitpack.io") + url = uri("https://maven.pkg.github.com/revanced/revanced-patcher") + credentials { + username = githubUsername + password = githubPassword + } } + maven { url = uri("https://jitpack.io") } + google() } dependencies { - implementation("org.jetbrains.kotlin:kotlin-stdlib:1.6.21") + implementation("org.jetbrains.kotlin:kotlin-stdlib:1.7.0") implementation("app.revanced:revanced-patcher:1.1.0") implementation("info.picocli:picocli:4.6.3") implementation("com.android.tools.build:apksig:7.2.1") implementation("com.github.revanced:jadb:master-SNAPSHOT") // updated fork implementation("org.bouncycastle:bcpkix-jdk15on:1.70") - implementation("org.jetbrains.kotlin:kotlin-reflect:1.6.21") -} - -java { - withSourcesJar() - withJavadocJar() + implementation("org.jetbrains.kotlin:kotlin-reflect:1.7.0") } tasks { @@ -50,22 +50,4 @@ tasks { attributes("Implementation-Version" to project.version) } } -} - -publishing { - repositories { - maven { - name = "GitHubPackages" - url = uri("https://maven.pkg.github.com/revanced/revanced-cli") - credentials { - username = System.getenv("GITHUB_ACTOR") - password = System.getenv("GITHUB_TOKEN") - } - } - } - publications { - register("gpr") { - from(components["java"]) - } - } -} +} \ No newline at end of file