LeraRiemann / ProjectInfinity

https://modrinth.com/mod/infinite-dimensions
7 stars 4 forks source link

Modify config generation to use the `File.separator` value instead of a hardcoded "/" #33

Closed JPeroutek closed 2 months ago

JPeroutek commented 2 months ago

The config JSON files fail to copy when building on Windows, due to the use of the incorrect file path separator ("/").

JPeroutek commented 2 months ago

Relevant issue #31

LeraRiemann commented 2 months ago

merged your request but it looks like your change leads to further issues with actually running the mod on windows: issue #34 so i might have to undo the change sadly

JPeroutek commented 2 months ago

Hmm, thats odd. I will take another look soon. It was a bit strange, I was able to run the mod locally in a fabric instance, however I couldn't run the mod in my dev environment after building locally.

cassiancc commented 2 months ago

@JPeroutek, would you be able to build and test my branch? I've gone through and replaced all the hardcoded slashes, and I want to check if it works on Windows or not. https://github.com/cassiancc/ProjectInfinity/tree/bugfix/path-seperator

JPeroutek commented 2 months ago

I was able to build and run your branch locally while in Intellij, however upon copying the created JAR file to a test 1.20.1 instance, I got this crash: https://paste.ee/p/2so4n

LeraRiemann commented 2 months ago

the mod isn't supposed to run on 1.21 at all though, it's for 1.20.1

JPeroutek commented 2 months ago

@LeraRiemann correct, I mis-spoke (mistyped?) the instance is 1.20.1, as seen in the log file, not 1.21.

cassiancc commented 2 months ago

I believe I've solved it. Windows seems to only use File.separator in development, and not outside IntelliJ. I've created a PR with this fix that works in both development and production on Windows, https://github.com/LeraRiemann/ProjectInfinity/pull/36