Skip to content

Commit

Permalink
ci: Set up ci-controlled platform publishing from GitHub Releases (#1082
Browse files Browse the repository at this point in the history
)

Publishing tasks are configured to debug mode for now to avoid actual publishing

merged from #1082
  • Loading branch information
bconlon1 authored Mar 21, 2023
1 parent f55e53b commit c009371
Show file tree
Hide file tree
Showing 4 changed files with 54 additions and 3 deletions.
5 changes: 4 additions & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,10 @@ jobs:
GRADLE_OPTS: -Dorg.gradle.daemon=false
steps:
- setup
- run: gradle publish
- run: |
gradle publish
gradle curseforge
gradle modrinth
commands:
setup:
Expand Down
46 changes: 44 additions & 2 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@ buildscript {
classpath group: 'org.spongepowered', name: 'mixingradle', version: '0.7.+', changing: true
classpath group: 'org.parchmentmc', name: 'librarian', version: '1.+', changing: true
classpath group: 'io.github.0ffz', name: 'gpr-for-gradle', version: '1.+', changing: true
classpath group: 'gradle.plugin.com.matthewprenger', name: 'CurseGradle', version: '1.4.+', changing: true
classpath group: 'com.modrinth.minotaur', name: 'Minotaur', version: '2.+', changing: true
}
}
apply plugin: 'net.minecraftforge.gradle'
Expand All @@ -31,6 +33,8 @@ apply plugin: 'org.parchmentmc.librarian.forgegradle'
apply plugin: 'eclipse'
apply plugin: 'maven-publish'
apply plugin: 'io.github.0ffz.github-packages'
apply plugin: 'com.matthewprenger.cursegradle'
apply plugin: 'com.modrinth.minotaur'

version = project.mc_version + '-' + project.aether_version
group = 'com.gildedgames.aether' // http://maven.apache.org/guides/mini/guide-naming-conventions.html
Expand Down Expand Up @@ -139,7 +143,7 @@ repositories {
maven { url = "https://maven.theillusivec4.top/" }
maven { url = "https://www.cursemaven.com" }
maven { url = "https://dvs1.progwml6.com/files/maven/" }
maven { url "https://gitlab.com/api/v4/projects/21830712/packages/maven" }
maven { url = "https://gitlab.com/api/v4/projects/21830712/packages/maven" }
// maven githubPackage.invoke("Gilded-Games/Nitrogen")
}

Expand Down Expand Up @@ -201,11 +205,49 @@ publishing {
}
}

curseforge {
project {
apiKey = System.getenv("CURSEFORGE_TOKEN")
id = "${project.curseforge_id}"
releaseType = "${project.version_type}"
changelog = file("./docs/CHANGELOG.md")
changelogType = "markdown"
addGameVersion("${project.mc_version}")
mainArtifact(tasks.jar) {
displayName = "The Aether ${version}"
relations {
embeddedLibrary "curios"
optionalDependency "starlight-forge"
}
}
}
options {
debug = true
}
}

modrinth {
token = System.getenv("MODRINTH_TOKEN")
projectId = "${project.modrinth_id}"
versionNumber = "${version}"
versionType = "${project.version_type}"
versionName = "The Aether ${version}"
changelog = new File("./docs/CHANGELOG.md").text
uploadFile = tasks.jar
gameVersions = ["${project.mc_version}"]
loaders = ["forge"]
dependencies {
embedded.version "curios", "${project.curios_version}"
optional.project "starlight-forge"
}
debugMode = true
}

mixin {
config "aether.mixins.json"
add sourceSets.main, "aether.refmap.json"
}

build {
dependsOn 'jarJar'
}
}
1 change: 1 addition & 0 deletions docs/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
test changelog
5 changes: 5 additions & 0 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -21,3 +21,8 @@ caelus_version=1.19.4-3.0.0.10
#colytra_version=3310142
#https://www.curseforge.com/minecraft/mc-mods/curious-elytra/files/3601975
#curiouselytra_version=3601975

# Publishing
curseforge_id=255308
modrinth_id=YhmgMVyu
version_type=beta

0 comments on commit c009371

Please sign in to comment.