Slurp mod version from json to avoid issues in IDE #113

Open
liach wants to merge 1 commits from liachmodded/feature/version-slurping into 1.17
liach commented 2021-06-24 16:01:11 +00:00 (Migrated from github.com)
See FabricMC/fabric-loader#457 Signed-off-by: liach <liach@users.noreply.github.com>
dexman545 commented 2021-06-24 16:24:57 +00:00 (Migrated from github.com)

I don't think this is suitable for the example mod - other mod properties are set in gradle.properties, it shouldn't be inverted for this one special thing. If auto-run of processResources is really so generally needed, then adding things like Idea's extension so that processResources being autorun will already be configured, or a possible loom change to make it so.

I don't think this is suitable for the example mod - other mod properties are set in gradle.properties, it shouldn't be inverted for this one special thing. If auto-run of processResources is really so generally needed, then adding things like Idea's extension so that processResources being autorun will already be configured, or a possible loom change to make it so.
jackassmc commented 2021-06-24 16:33:05 +00:00 (Migrated from github.com)

Some properties are set in gradle.properties others are set in fabric.mod.json. When using the example mod you'll end up editing both of these files eventually.

Some properties are set in `gradle.properties` others are set in `fabric.mod.json`. When using the example mod you'll end up editing both of these files eventually.
liach commented 2021-06-24 16:40:21 +00:00 (Migrated from github.com)

For @dexman545, I don't think it's quite easy to set the run configurations' resource classpath to the output of processresources. If we can add a correct dependency on process resources for loom, it's good too, but doing it correctly is a bit hard.

For @dexman545, I don't think it's quite easy to set the run configurations' resource classpath to the output of processresources. If we can add a correct dependency on process resources for loom, it's good too, but doing it correctly is a bit hard.
dexman545 commented 2021-06-24 16:59:26 +00:00 (Migrated from github.com)

I'm not sure about what loom can do, but it is worth mentioning as a possibility.

Yes, you modify both files - that does not change the fact that gradle.properties is the correct place for mod version to be set. Few people need this functionality that while it would be good to have, it should be a background thing in loom, not a reworking of the example mod.

I'm not sure about what loom can do, but it is worth mentioning as a possibility. Yes, you modify both files - that does not change the fact that `gradle.properties` is the correct place for mod version to be set. Few people need this functionality that while it would be good to have, it should be a background thing in loom, not a reworking of the example mod.
sfPlayer1 commented 2021-06-24 20:08:08 +00:00 (Migrated from github.com)

I don't buy into this gradle.properties argument, it obviously breaks in-dev use and alters the product in ways that are too extensive for a build system - a version is no build ID. Neither does it make a different to edit one file or another, having to change both is rare.

Running gradle in the IDE is not a solution, it turns instant run (esp. Eclipse) into waiting for gradle to start+finish and complicates the project setup.

I don't buy into this gradle.properties argument, it obviously breaks in-dev use and alters the product in ways that are too extensive for a build system - a version is no build ID. Neither does it make a different to edit one file or another, having to change both is rare. Running gradle in the IDE is not a solution, it turns instant run (esp. Eclipse) into waiting for gradle to start+finish and complicates the project setup.
jackassmc commented 2021-06-26 14:54:48 +00:00 (Migrated from github.com)

Is this blocked until the loader version override is available or can this be merged already?

Is this blocked until the loader version override is available or can this be merged already?
halotroop2288 (Migrated from github.com) approved these changes 2021-09-11 04:30:42 +00:00
modmuss50 commented 2021-09-11 12:04:42 +00:00 (Migrated from github.com)

I added a thing to loom to do this nicely: 2c464cdef3 Will need to wait for a stable build of 0.10

I added a thing to loom to do this nicely: https://github.com/FabricMC/fabric-loom/commit/2c464cdef372e92ea719eec618ae713d54cede89 Will need to wait for a stable build of 0.10
halotroop2288 commented 2021-09-11 15:06:35 +00:00 (Migrated from github.com)

I added a thing to loom to do this nicely
Will need to wait for a stable build of 0.10

What about 0.7?

> I added a thing to loom to do this nicely > Will need to wait for a stable build of 0.10 What about 0.7?
modmuss50 commented 2021-09-11 15:10:35 +00:00 (Migrated from github.com)

What about 0.7?

What do you mean? 0.10 is the version that is being developed atm and will be made stable once its ready. 0.7 was completed long ago.

> What about 0.7? What do you mean? 0.10 is the version that is being developed atm and will be made stable once its ready. 0.7 was completed long ago.
halotroop2288 commented 2021-09-11 15:32:17 +00:00 (Migrated from github.com)

0.7 was completed long ago.

So this feature is already in 0.7 for those of us who still use Java 8 versions?

If it's not, this should be changed:
image

> 0.7 was completed long ago. So this feature is already in 0.7 for those of us who still use Java 8 versions? If it's not, this should be changed: ![image](https://user-images.githubusercontent.com/30361266/132953159-f3591ace-cb90-4ed6-b207-202eee239ecd.png)
modmuss50 commented 2021-09-11 16:03:31 +00:00 (Migrated from github.com)

I should update the site, 0.9 is recommended for everyone, you can still use it build mods for java 8 (see fabric API's 1.16 branch)

I should update the site, 0.9 is recommended for everyone, you can still use it build mods for java 8 (see fabric API's 1.16 branch)
This pull request has changes conflicting with the target branch.
  • gradle.properties

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin liachmodded/feature/version-slurping:liachmodded/feature/version-slurping
git checkout liachmodded/feature/version-slurping
Sign in to join this conversation.
No reviewers
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: Steven/fabric-example-mod#113
No description provided.