-
Notifications
You must be signed in to change notification settings - Fork 211
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Intellij Run configurations don't include resourceProcessing #1010
Comments
On Fabric, people generally don't use variable expansion in their resources like that. If you don't then you can even set "Build with" to IDEA instead of Gradle for hopefully faster compile times. |
@Technici4n The official fabric gradle template uses it: https://github.com/FabricMC/fabric-example-mod/blob/1.20/build.gradle#L52 |
And the default MinecraftDev IDEA plugin templates extend this to fill in the loader_version and minecraft_version: https://github.com/minecraft-dev/MinecraftDev/blob/dev/src/main/resources/fileTemplates/j2ee/fabric/fabric_build.gradle.ft#L41-L42 So I don't think it's correct to say this isn't commonly done. A quick github search shows that 15k mods have this property defined: For example, this snippet from Create: https://github.com/Fabricators-of-Create/Create/blob/49cc17e/build.gradle#L188-L213 |
This is an intelij limitation, sadly nothing we can do to fix it (loom has nothing to do with processResources anyway). I would reccomend not using the MC dev template, the official template (https://fabricmc.net/develop/template/) does not do this, and works great when building+running via idea. |
@modmuss50 there's no way to run a single short gradle script to process the resources during the intellij Before Launch phase? That doesn't seem correct to me, Intellij definitely provides the tools to do so The official template you provided still has the same conceptual issue, in that it uses the The fact that all fabric developers are prevented from using build variables in their fabric.mod.json file if they want resource reloading is a major issue and I think as a project we could do a better job leveraging the capabilities of the IDE to solve this |
Not really no, as doing so would then remove the main benefit (the major peformance improvement) of building without gradle.
This was done on purpose, loom does provide the tools to read the mod version from the fabric.mod.json and set it as the Gradle version, maybe we should do that in the example mod and remove process resources 🤔 |
I just want to be able to type /reload and get updated versions of my
datapacks when i edit them. I haven't really ever seen a performance
difference between running my mod through IntelliJ or through Gradle
(starting up the instance and doing mixins is always much longer than
compiling the code anyway)
…On Sun, Jan 7, 2024 at 10:39 AM modmuss ***@***.***> wrote:
@modmuss50 <https://github.com/modmuss50> there's no way to run a single
short gradle script to process the resources during the intellij Before
Launch phase? That doesn't seem correct to me, Intellij definitely provides
the tools to do so
Not really no, as doing so would then remove the main benefit (the major
peformance improvement) of building without gradle.
Fabric just happens not to crash
This was done on purpose, loom does provide the tools to read the mod
version from the fabric.mod.json and set it as the Gradle version, maybe we
should do that in the example mod and remove process resources 🤔
—
Reply to this email directly, view it on GitHub
<#1010 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AABZCV6VN6HWOK5H6N3GX6LYNLFUZAVCNFSM6AAAAABA5MBRAKVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQOBQGEYDQMBTGM>
.
You are receiving this because you authored the thread.Message ID:
***@***.***>
|
Hi all! A bit confused about where to begin with this report, but I'm trying to use the "Minecraft Client" run configurations generated by loom, but they fail because my
fabric.mod.json
file requires some template processing from Gradle before it can be used:which gives me an error:
the
gradle :runClient
tasks work fine, but that seems to make it harder to debug & slower to compile. Plus, I don't think it works with hot reloading?This seems like a bug in that the "Minecraft Client" should have a Before Build task to pre-process the resources and put them in the right place (wherever that may be).
Presumably this would also break for anybody with generated data?
The text was updated successfully, but these errors were encountered: