Skip to content

Commit

Permalink
fix gradle file
Browse files Browse the repository at this point in the history
  • Loading branch information
skiprocks999 committed Nov 26, 2024
1 parent 0d45eb6 commit 9954752
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 1 deletion.
21 changes: 21 additions & 0 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,22 @@ dependencies {

}

tasks.register('sourcesJar', Jar).configure {
dependsOn classes
from sourceSets.main.allSource
archiveClassifier = 'sources'
}

tasks.register('deobfJar', Jar).configure {
from sourceSets.main.output
archiveClassifier = 'deobf'
}

tasks.named('publish').configure {
dependsOn 'reobfJar'
}


tasks.withType(ProcessResources).configureEach {
var replaceProperties = [
minecraft_version : minecraft_version,
Expand All @@ -108,6 +124,11 @@ tasks.withType(ProcessResources).configureEach {
}
}

artifacts {
archives sourcesJar
archives deobfJar
}

publishing {
publications {
register('mavenJava', MavenPublication) {
Expand Down
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ org.gradle.jvmargs=-Xmx3G
org.gradle.daemon=false

# Electrodynamics parameters
mod_version=0.9.1-0
mod_version=0.10.0-0
mod_id=electrodynamics
mod_group_id=electrodynamics
mod_name=Electrodynamics
Expand Down

0 comments on commit 9954752

Please sign in to comment.