Replace nebula-publishing for maven-publish, remove bintray release action
This commit is contained in:
29
.github/workflows/release-to-bintray.yml
vendored
29
.github/workflows/release-to-bintray.yml
vendored
@@ -1,29 +0,0 @@
|
|||||||
name: Release to Bintray
|
|
||||||
on:
|
|
||||||
push:
|
|
||||||
tags:
|
|
||||||
- v[0-9].[0-9]+.[0-9]+
|
|
||||||
jobs:
|
|
||||||
build:
|
|
||||||
runs-on: ubuntu-18.04
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@v2
|
|
||||||
- name: Get the version
|
|
||||||
id: get_version
|
|
||||||
run: echo ::set-output name=VERSION::${GITHUB_REF/refs\/tags\/v/}
|
|
||||||
- uses: actions/setup-java@v1
|
|
||||||
with:
|
|
||||||
java-version: 8
|
|
||||||
- name: Build and publish to local maven
|
|
||||||
run: ./gradlew -Prelease.useLastTag=true release publishToMavenLocal --info
|
|
||||||
- name: Zip and publish to Bintray
|
|
||||||
run: |
|
|
||||||
cd ~/.m2/repository
|
|
||||||
zip release.zip org/openrndr/extra/*/${{ steps.get_version.outputs.VERSION }}/*
|
|
||||||
curl -u ${{ secrets.BINTRAY_USER }}:${{ secrets.BINTRAY_KEY }} -X PUT https://api.bintray.com/content/openrndr/openrndr/ \
|
|
||||||
-H "X-Bintray-Package:orx" \
|
|
||||||
-H "X-Bintray-Version:${{ steps.get_version.outputs.VERSION }}" \
|
|
||||||
-H "X-Bintray-Publish:1" \
|
|
||||||
-H "X-Bintray-Override:1" \
|
|
||||||
-H "X-Bintray-Explode:1" \
|
|
||||||
-T release.zip
|
|
||||||
27
.github/workflows/release-to-maven-central.yml
vendored
Normal file
27
.github/workflows/release-to-maven-central.yml
vendored
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
name: Release to Bintray
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
tags:
|
||||||
|
- v[0-9].[0-9]+.[0-9]+
|
||||||
|
jobs:
|
||||||
|
build:
|
||||||
|
runs-on: ubuntu-18.04
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
- name: Get the version
|
||||||
|
id: get_version
|
||||||
|
run: echo ::set-output name=VERSION::${GITHUB_REF/refs\/tags\/v/}
|
||||||
|
- uses: actions/setup-java@v1
|
||||||
|
with:
|
||||||
|
java-version: 8
|
||||||
|
- name: Build and publish to local maven
|
||||||
|
run: ./gradlew -Prelease.useLastTag=true build
|
||||||
|
- name: Decode
|
||||||
|
run: |
|
||||||
|
echo "${{secrets.SIGNING_SECRET_KEY_RING_FILE}}" > ~/.gradle/secring.gpg.b64
|
||||||
|
base64 -d ~/.gradle/secring.gpg.b64 > ~/.gradle/secring.gpg
|
||||||
|
- name: Publish
|
||||||
|
run: ./gradlew publish -Prelease.useLastTag=true -Psigning.keyId=${{secrets.SIGNING_KEY_ID}} -Psigning.password=${{secrets.SIGNING_KEY_PASSWORD}} -Psigning.secretKeyRingFile=$(echo ~/.gradle/secring.gpg)
|
||||||
|
env:
|
||||||
|
OSSRH_USERNAME: ${{secrets.OSSRH_USERNAME}}
|
||||||
|
OSSRH_PASSWORD: ${{secrets.OSSRH_PASSWORD}}
|
||||||
94
build.gradle
94
build.gradle
@@ -1,10 +1,11 @@
|
|||||||
|
import org.gradle.nativeplatform.platform.internal.DefaultNativePlatform
|
||||||
|
|
||||||
buildscript {
|
buildscript {
|
||||||
repositories {
|
repositories {
|
||||||
jcenter()
|
jcenter()
|
||||||
}
|
}
|
||||||
dependencies {
|
dependencies {
|
||||||
classpath "org.jetbrains.dokka:dokka-gradle-plugin:0.9.17"
|
classpath "org.jetbrains.dokka:dokka-gradle-plugin:0.9.17"
|
||||||
classpath "com.netflix.nebula:nebula-publishing-plugin:17.3.0"
|
|
||||||
classpath "com.netflix.nebula:nebula-release-plugin:15.1.0"
|
classpath "com.netflix.nebula:nebula-release-plugin:15.1.0"
|
||||||
classpath "com.github.ben-manes:gradle-versions-plugin:0.28.0"
|
classpath "com.github.ben-manes:gradle-versions-plugin:0.28.0"
|
||||||
}
|
}
|
||||||
@@ -17,6 +18,8 @@ def openrndrUseSnapshot = false
|
|||||||
|
|
||||||
apply plugin: 'org.jetbrains.dokka'
|
apply plugin: 'org.jetbrains.dokka'
|
||||||
|
|
||||||
|
ext.isReleaseVersion = !version.endsWith("SNAPSHOT")
|
||||||
|
|
||||||
project.ext {
|
project.ext {
|
||||||
openrndrVersion = openrndrUseSnapshot? "0.4.0-SNAPSHOT" : "0.3.47"
|
openrndrVersion = openrndrUseSnapshot? "0.4.0-SNAPSHOT" : "0.3.47"
|
||||||
kotlinVersion = "1.4.32"
|
kotlinVersion = "1.4.32"
|
||||||
@@ -53,13 +56,8 @@ allprojects {
|
|||||||
apply plugin: 'idea'
|
apply plugin: 'idea'
|
||||||
apply plugin: 'java'
|
apply plugin: 'java'
|
||||||
apply plugin: 'kotlin'
|
apply plugin: 'kotlin'
|
||||||
apply plugin: 'nebula.contacts'
|
|
||||||
apply plugin: 'nebula.info'
|
|
||||||
apply plugin: 'nebula.release'
|
apply plugin: 'nebula.release'
|
||||||
apply plugin: 'nebula.maven-publish'
|
|
||||||
|
|
||||||
apply plugin: 'nebula.source-jar'
|
|
||||||
apply plugin: 'nebula.javadoc-jar'
|
|
||||||
apply plugin: "com.github.ben-manes.versions"
|
apply plugin: "com.github.ben-manes.versions"
|
||||||
|
|
||||||
group 'org.openrndr.extra'
|
group 'org.openrndr.extra'
|
||||||
@@ -71,9 +69,6 @@ allprojects {
|
|||||||
|
|
||||||
mavenCentral()
|
mavenCentral()
|
||||||
jcenter()
|
jcenter()
|
||||||
maven {
|
|
||||||
url = "https://dl.bintray.com/openrndr/openrndr"
|
|
||||||
}
|
|
||||||
maven {
|
maven {
|
||||||
url "https://dl.bintray.com/spekframework/spek"
|
url "https://dl.bintray.com/spekframework/spek"
|
||||||
}
|
}
|
||||||
@@ -102,13 +97,6 @@ allprojects {
|
|||||||
options.addBooleanOption 'Xdoclint:none', true
|
options.addBooleanOption 'Xdoclint:none', true
|
||||||
}
|
}
|
||||||
|
|
||||||
contacts {
|
|
||||||
'edwin@openrndr.org' {
|
|
||||||
moniker 'Edwin Jakobs'
|
|
||||||
github 'edwinRNDR'
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
test {
|
test {
|
||||||
useJUnitPlatform {
|
useJUnitPlatform {
|
||||||
includeEngines 'spek2'
|
includeEngines 'spek2'
|
||||||
@@ -261,6 +249,80 @@ task collectScreenshots {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
configure(allprojects.findAll { it.name != "openrndr-demos" }) {
|
||||||
|
apply plugin: 'nebula.release'
|
||||||
|
apply plugin: 'maven-publish'
|
||||||
|
apply plugin: 'signing'
|
||||||
|
|
||||||
|
java {
|
||||||
|
withJavadocJar()
|
||||||
|
withSourcesJar()
|
||||||
|
}
|
||||||
|
|
||||||
|
publishing {
|
||||||
|
publications {
|
||||||
|
mavenJava(MavenPublication) {
|
||||||
|
from components.java
|
||||||
|
groupId = "org.openrndr.extra"
|
||||||
|
artifactId = "$project.name"
|
||||||
|
|
||||||
|
description = "$project.name"
|
||||||
|
pom {
|
||||||
|
name = "$project.name"
|
||||||
|
description = "$project.name"
|
||||||
|
url = 'http://openrndr.org'
|
||||||
|
developers {
|
||||||
|
developer {
|
||||||
|
id = 'edwinjakobs'
|
||||||
|
name = 'Edwin Jakobs'
|
||||||
|
email = 'edwin@openrndr.org'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
license {
|
||||||
|
licenses {
|
||||||
|
license {
|
||||||
|
name = 'BSD-2-Clause'
|
||||||
|
url = 'https://github.com/openrndr/openrndr/blob/master/LICENSE'
|
||||||
|
distribution = 'repo'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
scm {
|
||||||
|
connection = "scm:git:git@github.com:openrndr/openrndr.git"
|
||||||
|
developerConnection = "scm:git:ssh://github.com/openrndr/openrndr.git"
|
||||||
|
url = "https://github.com/openrndr/openrndr"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
repositories {
|
||||||
|
maven {
|
||||||
|
credentials {
|
||||||
|
username findProperty("ossrhUsername") ?: System.getenv("OSSRH_USERNAME")
|
||||||
|
password findProperty("ossrhPassword") ?: System.getenv("OSSRH_PASSWORD")
|
||||||
|
}
|
||||||
|
if (!isReleaseVersion) {
|
||||||
|
url "https://s01.oss.sonatype.org/content/repositories/snapshots"
|
||||||
|
} else {
|
||||||
|
url "https://s01.oss.sonatype.org/service/local/staging/deploy/maven2"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
signing {
|
||||||
|
required { isReleaseVersion && gradle.taskGraph.hasTask("publish") }
|
||||||
|
sign publishing.publications.mavenJava
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
configure(subprojects) {
|
||||||
|
tasks.withType(org.jetbrains.kotlin.gradle.tasks.AbstractKotlinCompile).all {
|
||||||
|
kotlinOptions.freeCompilerArgs += ["-Xuse-experimental=kotlinx.coroutines.InternalCoroutinesApi"]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
collectScreenshots.dependsOn {
|
collectScreenshots.dependsOn {
|
||||||
project.subprojects.findAll { it.sourceSets.hasProperty("demo") }.collect { it.tasks.demoClasses }
|
project.subprojects.findAll { it.sourceSets.hasProperty("demo") }.collect { it.tasks.demoClasses }
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user