Skip to content

Commit

Permalink
Merge pull request #170 from refinedmods/release/0.16.9
Browse files Browse the repository at this point in the history
Release v0.16.9
  • Loading branch information
raoulvdberge authored Jul 25, 2024
2 parents d5550c9 + 2573f20 commit 18965b3
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 21 deletions.
10 changes: 9 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,12 @@ to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [Unreleased]

## [0.16.9] - 2024-07-25

### Fixed

- Declaring `fabric()` without a `modId` set will not create a mod or run configs. Can be used for a Fabric library module.

## [0.16.8] - 2024-07-23

### Fixed
Expand Down Expand Up @@ -345,7 +351,9 @@ to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
- Gradle helpers for Fabric and Forge projects.
- CI workflows.

[Unreleased]: https://github.com/refinedmods/refinedarchitect/compare/v0.16.8...HEAD
[Unreleased]: https://github.com/refinedmods/refinedarchitect/compare/v0.16.9...HEAD

[0.16.9]: https://github.com/refinedmods/refinedarchitect/compare/v0.16.8...v0.16.9

[0.16.8]: https://github.com/refinedmods/refinedarchitect/compare/v0.16.7...v0.16.8

Expand Down
43 changes: 23 additions & 20 deletions refinedarchitect-plugin/src/main/kotlin/FabricExtension.kt
Original file line number Diff line number Diff line change
Expand Up @@ -20,28 +20,30 @@ open class FabricExtension(private val project: Project) : BaseExtension(project
project.dependencies.add("modImplementation", "net.fabricmc:fabric-loader:${fabricLoaderVersion}")
project.dependencies.add("modImplementation", "net.fabricmc.fabric-api:fabric-api:${fabricApiVersion}")

project.extensions.getByType<LoomGradleExtensionAPI>().apply {
val accessWidenerFile = project.file("src/main/resources/${modId!!}.accesswidener")
if (accessWidenerFile.exists()) {
accessWidenerPath.set(accessWidenerFile)
}
runs {
getByName("client") {
client()
setConfigName("Fabric Client")
ideConfigGenerated(true)
runDir("run")
if (modId != null) {
project.extensions.getByType<LoomGradleExtensionAPI>().apply {
val accessWidenerFile = project.file("src/main/resources/${modId!!}.accesswidener")
if (accessWidenerFile.exists()) {
accessWidenerPath.set(accessWidenerFile)
}
getByName("server") {
server()
setConfigName("Fabric Server")
ideConfigGenerated(true)
runDir("run")
runs {
getByName("client") {
client()
setConfigName("Fabric Client")
ideConfigGenerated(true)
runDir("run")
}
getByName("server") {
server()
setConfigName("Fabric Server")
ideConfigGenerated(true)
runDir("run")
}
}
mixin {
showMessageTypes.set(true)
messages.put("TARGET_ELEMENT_NOT_FOUND", "disabled")
}
}
mixin {
showMessageTypes.set(true)
messages.put("TARGET_ELEMENT_NOT_FOUND", "disabled")
}
}
project.tasks.withType<Jar>().configureEach {
Expand All @@ -55,6 +57,7 @@ open class FabricExtension(private val project: Project) : BaseExtension(project
}

fun compileWithProject(dependency: Project) {
project.evaluationDependsOn(":" + dependency.name)
val sourceSets = dependency.extensions.getByType<JavaPluginExtension>().sourceSets
project.tasks.withType<JavaCompile>().configureEach {
source(sourceSets["main"].allSource)
Expand Down

0 comments on commit 18965b3

Please sign in to comment.