Commit Graph

31 Commits (5a16440c1efec12870953e369f0f481d37c16b23)

Author SHA1 Message Date
modmuss50 5a16440c1e
Support ARM natives, rewrite native handling and misc cleanup. (#554)
* Rewrite natives handling, upgrade LWJGL on ARM machines.

* Remove old natives override hack, should now always be done via gradle.

* Use "idea" everywhere

* Add server specific libraries onto their own classpath. Includes misc code cleanup.

* Start on writing the excluded server libs.

* Gradle deprecation fixes, and misc cleanup

* Add support mod.

* Make native support mod none transitive.

* Update gradle.
2021-12-17 15:37:00 +00:00
modmuss50 6d65e120e7 Remove deprecated stuff 2021-12-04 19:00:47 +00:00
modmuss50 b550ca7857
Validate remapped mods also have a remapped access widener. (#549)
* Validate remapped mods also have a remapped access widener.

* Fix checkstyle
2021-12-02 18:59:47 +00:00
modmuss50 35afda4398
Fix `namedElements` not extending from api (#533)
* Fix `namedElements` not extending from api
Fix artifact not waiting for remapAllJars with shared caches

* Use apiElements

* Add a better test for this.

* Also add remapped api mods to namedElements
2021-11-12 10:46:23 +00:00
shedaniel 5c190cc3ef
Use NIO instead of ZipUtil (#513)
* Use nio for zip utils

* Make tests work

* Please work

* Fix some issues with tests

* Fix more issues with tests

* NIOZipUtils -> ZipUtils

* Resolve Juuxel's reviews

* Use our own FS utils

* Improve error handling, add loom Pair

* Add Unit tests + fixes

Co-authored-by: modmuss50 <modmuss50@gmail.com>
2021-10-26 13:08:17 +01:00
modmuss50 8da2da8aed Update checkstyle to prevent using var expect for new instance creation. 2021-09-07 11:55:05 +01:00
Logic 3b0dc7f0f4
Use tiny-remapper to remap mixin annotation. (#441)
* use tiny-remapper 0.5.0

* add property of useLegacyMixinAp and rename mixin to mixinAp

* disable mixin ap if useLegacyMixinAp is false

* fix tests

* remove experimental for mixinAp

* enable mixin remapper

* revert changes on API

* rename MixinAp*** to Mixin***

* move useLegacyMixinAp inside MixinExtension

* cleaner code

* update test

Co-authored-by: modmuss50 <modmuss50@gmail.com>
2021-09-07 11:28:51 +01:00
modmuss50 3ded0964c4
Refactor and improve tests (#466)
* Install and run a production server in tests

* Small improvements

* Add FabricAPI build test
Create new GradleProjectTestTrait replacing the old trait
Improve groovy code formatting.

* Refactor tests

* Fix MultiProjectTest + fix logging for fabric api test

* Cleanup and fixes

* Update fabric api + run in parallel for speed

* Set server memory + fix error
2021-08-31 11:48:58 +01:00
shedaniel 97a629eef9
File Structure Changes (#462)
* File Structure changes

* Fix checkstyle

* Fix processed jars

* Fix unpick tests

* Resolve reviews

* Fix merge conflicts
2021-08-13 21:02:45 +01:00
Juuxel a0c2d877af
Add modCompileOnlyApi, modRuntimeOnly; deprecate modRuntime (#458) 2021-07-31 23:46:42 +01:00
Logic e124d48387
fix #448 (#451)
* fix #448

* minor fix
2021-07-28 08:50:14 +01:00
shedaniel 75234f4cbd
Use Property in LoomGradleExtension & Move task groups to constants (#445)
* Use Property in LoomGradleExtension

Signed-off-by: shedaniel <daniel@shedaniel.me>

* Fix customMinecraftManifest

Signed-off-by: shedaniel <daniel@shedaniel.me>

* Add deprecation messages, let's wait for the tests to run to fix the tests that are using deprecated apis

Signed-off-by: shedaniel <daniel@shedaniel.me>

* Apply license

Signed-off-by: shedaniel <daniel@shedaniel.me>

* Update src/main/java/net/fabricmc/loom/util/DeprecationHelper.java

Co-authored-by: Juuxel <6596629+Juuxel@users.noreply.github.com>

* Fix some tests, move mixinRefmapName -> mixin.defaultRefmapName

Signed-off-by: shedaniel <daniel@shedaniel.me>

* Move back to the api

Signed-off-by: shedaniel <daniel@shedaniel.me>

* Fix some tests

Signed-off-by: shedaniel <daniel@shedaniel.me>

* Apply reviews

Signed-off-by: shedaniel <daniel@shedaniel.me>

* Update src/main/java/net/fabricmc/loom/api/LoomGradleExtensionAPI.java

Co-authored-by: Juuxel <6596629+Juuxel@users.noreply.github.com>

Co-authored-by: Juuxel <6596629+Juuxel@users.noreply.github.com>
Co-authored-by: modmuss50 <modmuss50@gmail.com>
2021-07-26 20:08:03 +01:00
modmuss50 606046e719 Ensure files are closed and outputs cleaned up when remapping. 2021-07-23 21:22:59 +01:00
LogicFan 81fa551382
Better Mixin AP configuration (#423)
* [SPON-15] Apply Mixin AP config for all projects.

* Revert "[SPON-15] Apply Mixin AP config for all projects."

This reverts commit 93576e83b1221949d551b6307938f7dd6dc8fbbe.

* use setter & getter

* fix broken test introduced in 54d6ef7896

* initial commit for mixin extension

* refactor getConfiguration

* apply mixin extension

* [SPON-15] allow across project AP config

* [SPON-15] revert some changes

* [SPON-15] refactor codes

* [SPON-15] fix bugs

* [SPON-15] bring back cross-project apconfig

* [SPON-15] bug fix: move add default sourceSet earlier

* [SPON-15] fix style

* [SPON-15] refactor MixinAPExtension

* add test

* update test

* [SPON-15] fix test

* Update MixinAnnotationProcessorExtension.java

* [SPON-15] fix test

* fix deprecated gradle API

* [SPON-15] refactor ApInvoker

* [SPON-15] refactor ApInvoker

* allow change refmap name in sourceSet bases

* add new condition on test

* [SPON-15] fix wrong suffix

* Revert "[SPON-15] fix wrong suffix"

This reverts commit 98910392d91c26cd0454cca8cfc03c4e3d417fd6.

* fix mixinjson suffix

* use stream instead of collection for mixin json name

* change name for function

* use correct auto-refmap

* fix file name

* add with action

* add test

* refactor some codes

* refactor code

* update test

* fix checkstyle

* better error message

* fix checkstyle

* remove corss project option

* allow mixin inside loom

* remove project0

I should remove all project0. If I forget one please tell me.

* move `mixin` inside `loom`

* fix spotless

* merge attempt

* fix checkstyle

* seperate api & impl

* add experimental annotation for API

* use API

* Fix indentation

Co-authored-by: Juuxel <6596629+Juuxel@users.noreply.github.com>

* fix typo

Co-authored-by: Juuxel <6596629+Juuxel@users.noreply.github.com>

* fix typo

Co-authored-by: Juuxel <6596629+Juuxel@users.noreply.github.com>

* better javadoc

Co-authored-by: Juuxel <6596629+Juuxel@users.noreply.github.com>
2021-07-18 14:13:47 +01:00
modmuss50 e439a1b354
Refactor LoomGradleExtension (#431)
* First pass at refactoring the extension

* Fix inital issues.

* Combine some interfaces

* Checkstyle

* Fix years

* Add isShareCaches to api
2021-07-14 00:03:21 +01:00
Juuxel e9657d63c4
Fix local file mod dependencies (#430)
* ModProcessor: Add more descriptive error TR output error message

* Fix flatDir/files/fileTree mod dependencies

* Add clarifying comment

* Use hash as a placeholder version

* ProjectTestTrait: Copy instead of reading and writing text

This allows having jars and other binary data in tests.

* Add integration test for local file dependencies

* Use File.bytes instead of Files.copy

* Use truncated SHA256 instead of murmur3
2021-07-10 21:52:38 +01:00
modmuss50 54fe0909ff Use spotless for header validation, years have been back-filled from git history 2021-07-10 21:50:53 +01:00
modmuss50 188bbe57d6 Fix MergedNestedJarProvider not calling the child's prepare 2021-06-01 18:13:59 +01:00
Mitchell Skaggs 1f80e00e88
Add classifier to "fake" mods' id if they have a classifier specified (#394)
* Remove unused codepath (`RemapJarTask` is an `AbstractArchiveTask`)

* Remove incorrect comment

Comment originally added in 02e9616622

* Add classifier to `DependencyInfo`

* Add classifier to generated mod ID

* Clean up code structure from review

Co-authored-by: haykam821 <haykam821@users.noreply.github.com>

* Inline `file` local variable

Co-authored-by: haykam821 <haykam821@users.noreply.github.com>

Co-authored-by: haykam821 <haykam821@users.noreply.github.com>
2021-05-22 23:29:02 +01:00
modmuss50 9fb167d506
General cleanup by making use of java 16 features (#397)
* General cleanup by making use of java 16 features

* use jackson-databind in place of gson when reading to a record

* Fixes

* cleanup

* dep updates

* Replace commons IOUtils usage with native java

* Update fernflower
2021-05-13 22:06:34 +01:00
modmuss50 a5bc38a940 Make remapped configurations lazy 2021-05-04 19:07:21 +01:00
modmuss50 7231b9e053
Mod Remapping Refactor. (#362)
Improved gradle 7 support
General cleanup
2021-03-12 22:16:24 +00:00
modmuss50 409f5f8e93
Update MCE - Remove auto population of minVersion in mixins - Drop some log levels. 2021-02-11 18:12:27 +00:00
Jason 671328795e
Generate fabric.mod.json for included submodule jars (#343)
* Generate fabric.mod.json for included submodule jars

* Appease checkstyle
2021-02-02 23:03:57 +00:00
modmuss50 b622544cbe Dont remap dependency sources when building on CI services.
Use `-Dfabric.loom.ci=false` to force disable
2021-01-19 22:15:23 +00:00
modmuss50 58e94f2db3 Centralise refreshDeps variable.
Makes it easier to hack it to always enable for profiling.
2021-01-19 21:58:39 +00:00
modmuss50 9de836b2c4 Remove usage of internal kotlin class, should fix crash with kotlin 1.4. Closes #324 2021-01-07 20:35:43 +00:00
modmuss50 11b62989e7 Cleanup output files when remap fails. Fixes #321 2020-12-30 20:34:34 +00:00
modmuss50 841fc5a4db Fix classifier handling for remapped dependencies 2020-12-30 20:12:33 +00:00
modmuss50 792a64e2ef
Optimise loom configuration, saves 1.2 seconds in my testing. #319 2020-12-27 16:25:30 +00:00
modmuss50 03444f26b0
General code cleanup (#313)
* First general cleanup pass

* Review feedback

* Fix build

* Fix tests
2020-12-24 20:58:30 +00:00