mirror of
https://github.com/Creators-of-Create/Create.git
synced 2024-11-10 12:33:57 +01:00
haunted gradle
- Update forge - Add Flywheel to the runs when using Create/Flywheel gradle workspace - Fix weird intellij issues with mixin's annotation processor
This commit is contained in:
parent
df8f5449f0
commit
2bde87af33
32
build.gradle
32
build.gradle
@ -24,6 +24,9 @@ apply plugin: 'org.spongepowered.mixin'
|
|||||||
apply plugin: 'org.parchmentmc.librarian.forgegradle'
|
apply plugin: 'org.parchmentmc.librarian.forgegradle'
|
||||||
|
|
||||||
boolean dev = System.getenv('RELEASE') == null || System.getenv('RELEASE').equals('false');
|
boolean dev = System.getenv('RELEASE') == null || System.getenv('RELEASE').equals('false');
|
||||||
|
// jozu: I use a gradle workspace with both projects.
|
||||||
|
// The project is named Flywheel-Forge, but sub-projects are named by folder.
|
||||||
|
boolean inWorkspace = findProject(':Flywheel') != null
|
||||||
|
|
||||||
ext.buildnumber = 0
|
ext.buildnumber = 0
|
||||||
project.buildnumber = System.getenv('BUILD_NUMBER') != null ? System.getenv('BUILD_NUMBER') : 'custom'
|
project.buildnumber = System.getenv('BUILD_NUMBER') != null ? System.getenv('BUILD_NUMBER') : 'custom'
|
||||||
@ -51,6 +54,12 @@ minecraft {
|
|||||||
create {
|
create {
|
||||||
source sourceSets.main
|
source sourceSets.main
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (inWorkspace) {
|
||||||
|
flywheel {
|
||||||
|
source project(":Flywheel").sourceSets.main
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -64,6 +73,12 @@ minecraft {
|
|||||||
create {
|
create {
|
||||||
source sourceSets.main
|
source sourceSets.main
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (inWorkspace) {
|
||||||
|
flywheel {
|
||||||
|
source project(":Flywheel").sourceSets.main
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -78,6 +93,12 @@ minecraft {
|
|||||||
create {
|
create {
|
||||||
source sourceSets.main
|
source sourceSets.main
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (inWorkspace) {
|
||||||
|
flywheel {
|
||||||
|
source project(":Flywheel").sourceSets.main
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -139,8 +160,8 @@ dependencies {
|
|||||||
implementation fg.deobf(registrate)
|
implementation fg.deobf(registrate)
|
||||||
shade registrate
|
shade registrate
|
||||||
|
|
||||||
if (findProject(':Flywheel-Forge') != null) {
|
if (inWorkspace) {
|
||||||
implementation project(':Flywheel-Forge') // jozu: I use a gradle workspace with both projects
|
implementation project(':Flywheel')
|
||||||
} else {
|
} else {
|
||||||
implementation fg.deobf("com.jozufozu.flywheel:Flywheel-Forge:${flywheel_version}")
|
implementation fg.deobf("com.jozufozu.flywheel:Flywheel-Forge:${flywheel_version}")
|
||||||
}
|
}
|
||||||
@ -155,7 +176,12 @@ dependencies {
|
|||||||
// runtimeOnly fg.deobf("slimeknights.mantle:Mantle:1.16.5-1.6.115")
|
// runtimeOnly fg.deobf("slimeknights.mantle:Mantle:1.16.5-1.6.115")
|
||||||
// runtimeOnly fg.deobf("slimeknights.tconstruct:TConstruct:1.16.5-3.1.1.252")
|
// runtimeOnly fg.deobf("slimeknights.tconstruct:TConstruct:1.16.5-3.1.1.252")
|
||||||
|
|
||||||
annotationProcessor 'org.spongepowered:mixin:0.8.4:processor'
|
// https://discord.com/channels/313125603924639766/725850371834118214/910619168821354497
|
||||||
|
// Prevent Mixin annotation processor from getting into IntelliJ's annotation processor settings
|
||||||
|
// This allows 'Settings > Build, Execution, and Deployment > Build Tools > Gradle > Build and run using' set to IntelliJ to work correctly
|
||||||
|
if (System.getProperty('idea.sync.active') != 'true') {
|
||||||
|
annotationProcessor "org.spongepowered:mixin:${mixin_version}:processor"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
jar {
|
jar {
|
||||||
|
@ -6,11 +6,12 @@ org.gradle.daemon = false
|
|||||||
# mod version info
|
# mod version info
|
||||||
mod_version = 0.4
|
mod_version = 0.4
|
||||||
minecraft_version = 1.17.1
|
minecraft_version = 1.17.1
|
||||||
forge_version = 37.0.126
|
forge_version = 37.1.0
|
||||||
|
|
||||||
# build dependency versions
|
# build dependency versions
|
||||||
forgegradle_version = 5.1.+
|
forgegradle_version = 5.1.+
|
||||||
mixingradle_version = 0.7-SNAPSHOT
|
mixingradle_version = 0.7-SNAPSHOT
|
||||||
|
mixin_version = 0.8.5
|
||||||
librarian_version = 1.+
|
librarian_version = 1.+
|
||||||
shadow_version = 7.1.0
|
shadow_version = 7.1.0
|
||||||
cursegradle_version = 1.4.0
|
cursegradle_version = 1.4.0
|
||||||
|
Loading…
Reference in New Issue
Block a user