mirror of
https://github.com/architectury/architectury-api.git
synced 2026-03-28 03:56:59 -05:00
Publish to bintray
This commit is contained in:
1
.github/FUNDING.yml
vendored
Normal file
1
.github/FUNDING.yml
vendored
Normal file
@@ -0,0 +1 @@
|
||||
patreon: shedaniel
|
||||
19
.github/workflows/publish.yml
vendored
Normal file
19
.github/workflows/publish.yml
vendored
Normal file
@@ -0,0 +1,19 @@
|
||||
name: Java CI
|
||||
|
||||
on:
|
||||
[push]
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v1
|
||||
- name: Set up JDK 1.8
|
||||
uses: actions/setup-java@v1
|
||||
with:
|
||||
java-version: 1.8
|
||||
- name: Upload to Bintray
|
||||
run: ./gradlew bintrayUpload --stacktrace
|
||||
env:
|
||||
BINTRAY_USER: shedaniel
|
||||
BINTRAY_KEY: ${{ secrets.BINTRAY_KEY }}
|
||||
23
build.gradle
23
build.gradle
@@ -1,6 +1,9 @@
|
||||
plugins {
|
||||
id "architect-plugin" version "1.0.10"
|
||||
id "org.cadixdev.licenser" version "0.5.0"
|
||||
id "com.jfrog.bintray" version "1.8.4"
|
||||
id "maven"
|
||||
id "maven-publish"
|
||||
}
|
||||
|
||||
architect {
|
||||
@@ -13,7 +16,7 @@ allprojects {
|
||||
apply plugin: "org.cadixdev.licenser"
|
||||
|
||||
archivesBaseName = rootProject.archives_base_name
|
||||
version = rootProject.mod_version
|
||||
version = rootProject.mod_version + "." + (System.getenv("GITHUB_RUN_NUMBER") == null ? "9999" : (System.getenv("GITHUB_RUN_NUMBER").toInteger() - (int) project.last_minor_build).toString())
|
||||
group = rootProject.maven_group
|
||||
|
||||
tasks.withType(JavaCompile) {
|
||||
@@ -33,4 +36,20 @@ allprojects {
|
||||
}
|
||||
|
||||
task licenseFormatAll
|
||||
subprojects { p -> licenseFormatAll.dependsOn("${p.path}:licenseFormat") }
|
||||
subprojects { p -> licenseFormatAll.dependsOn("${p.path}:licenseFormat") }
|
||||
|
||||
bintray {
|
||||
user = project.hasProperty('bintrayUser') ? project.property('bintrayUser') : System.getenv('BINTRAY_USER')
|
||||
key = project.hasProperty('bintrayApiKey') ? project.property('bintrayApiKey') : System.getenv('BINTRAY_KEY')
|
||||
publications = ["mavenCommon", "mavenFabric", "mavenForge"]
|
||||
publish = true
|
||||
pkg {
|
||||
repo = "cloth"
|
||||
name = "architectury"
|
||||
userOrg = "shedaniel"
|
||||
licenses = ["Apache-2.0"]
|
||||
version {
|
||||
vcsUrl = "https://github.com/shedaniel/architectury.git"
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -13,4 +13,33 @@ dependencies {
|
||||
|
||||
architect {
|
||||
common()
|
||||
}
|
||||
|
||||
task sourcesJar(type: Jar, dependsOn: classes) {
|
||||
classifier = "sources"
|
||||
from sourceSets.main.allSource
|
||||
}
|
||||
|
||||
task javadocs(type: Javadoc) {
|
||||
source = sourceSets.main.allJava
|
||||
}
|
||||
|
||||
task javadocsJar(type: Jar, dependsOn: javadocs) {
|
||||
archiveClassifier.set("javadocs")
|
||||
javadocs.failOnError false
|
||||
from javadocs.destinationDir
|
||||
}
|
||||
|
||||
publishing {
|
||||
publications {
|
||||
mavenCommon(MavenPublication) {
|
||||
artifact(file("${project.buildDir}/libs/${project.archivesBaseName}-${project.version}.jar")) {
|
||||
builtBy build
|
||||
}
|
||||
artifact(sourcesJar) {
|
||||
builtBy remapSourcesJar
|
||||
}
|
||||
artifact javadocsJar
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -30,4 +30,16 @@ shadowJar {
|
||||
remapJar {
|
||||
dependsOn(shadowJar)
|
||||
input.set(shadowJar.archivePath)
|
||||
archiveClassifier = "fabric"
|
||||
}
|
||||
|
||||
publishing {
|
||||
publications {
|
||||
mavenFabric(MavenPublication) {
|
||||
artifact(file("${project.buildDir}/libs/${project.archivesBaseName}-${project.version}-fabric.jar")) {
|
||||
builtBy build
|
||||
classifier "fabric"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -3,7 +3,7 @@
|
||||
"id": "architectury",
|
||||
"version": "${version}",
|
||||
"name": "Architectury",
|
||||
"description": "This is an example description! Tell everyone what your mod is about!",
|
||||
"description": "A intermediary api aimed to ease developing multiplatform mods.",
|
||||
"authors": [
|
||||
"shedaniel"
|
||||
],
|
||||
|
||||
@@ -63,9 +63,20 @@ shadowJar {
|
||||
exclude "fabric.mod.json"
|
||||
|
||||
configurations = [project.configurations.shadow]
|
||||
classifier null
|
||||
classifier "forge"
|
||||
}
|
||||
|
||||
reobf {
|
||||
shadowJar {}
|
||||
}
|
||||
|
||||
publishing {
|
||||
publications {
|
||||
mavenFabric(MavenPublication) {
|
||||
artifact(file("${project.buildDir}/libs/${project.archivesBaseName}-${project.version}-forge.jar")) {
|
||||
builtBy shadowJar
|
||||
classifier "forge"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,7 +1,7 @@
|
||||
package me.shedaniel.architectury.registry.forge;
|
||||
|
||||
import com.google.common.collect.Lists;
|
||||
import me.shedaniel.architectury.registry.ReloadListenerRegistry;
|
||||
import me.shedaniel.architectury.registry.ReloadListeners;
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.resources.IFutureReloadListener;
|
||||
import net.minecraft.resources.IReloadableResourceManager;
|
||||
@@ -13,7 +13,7 @@ import net.minecraftforge.event.AddReloadListenerEvent;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public class ReloadListenersImpl implements ReloadListenerRegistry.Impl {
|
||||
public class ReloadListenersImpl implements ReloadListeners.Impl {
|
||||
private List<IFutureReloadListener> serverDataReloadListeners = Lists.newArrayList();
|
||||
|
||||
public ReloadListenersImpl() {
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
minecraft_version=1.16.3
|
||||
|
||||
archives_base_name=architectury
|
||||
mod_version=1.0.0
|
||||
mod_version=1.0.
|
||||
last_minor_build=1
|
||||
maven_group=me.shedaniel
|
||||
|
||||
fabric_loader_version=0.10.5+build.213
|
||||
|
||||
Reference in New Issue
Block a user