Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
37 commits
Select commit Hold shift + click to select a range
21ac945
build: Update to Gradle 8.8
Johni0702 Jul 8, 2025
ef66cdb
tests/fabric: Fix typos
Johni0702 Jul 7, 2025
3834fcc
tests/lw: Fix logging
Johni0702 Jul 7, 2025
3fcef54
tests/lw: Move tweaker-specific tests into dedicated file
Johni0702 Jul 7, 2025
b91a450
tests/lw: Move props utils to dedicated class
Johni0702 Jul 7, 2025
c5ddf9b
tests/lw: Move common stage1 tests to fabric project
Johni0702 Jul 7, 2025
ecead05
tests/lw: Move `sun.gg.essential.LoadState` into `minecraft` source set
Johni0702 Jul 7, 2025
abacc34
tests/lw: Move `dummyInitialized` to `LoadState`
Johni0702 Jul 7, 2025
e884862
tests/lw: Make `getBlackboard` work with relaunching
Johni0702 Jul 7, 2025
c3d312f
stage2/lw: Always relaunch
Johni0702 May 7, 2025
43524ee
tests/lw: Drop requirement for Essential to be excluded from LaunchCl…
Johni0702 Jul 7, 2025
a1e4e26
stage2/lw: Fix outdated comment
Johni0702 May 7, 2025
3554d8f
stage2/lw: Handle embedded stage1 via transformer instead of modifyin…
Johni0702 May 7, 2025
8c6a6eb
stage2/lw: Move stage0 tracking to separate class
Johni0702 May 13, 2025
4575622
stage2/lw: Move mixin tweaker injecting to separate class
Johni0702 May 13, 2025
09e3b77
stage2/lw: Copy additional code for MixinTweakerInjector from stage1
Johni0702 Jul 7, 2025
84df279
stage2/lw: Fix mixin appender cleanup with different class loader
Johni0702 Jul 8, 2025
e03ab9e
stage2/lw: Abstract away from always installing Essential
Johni0702 Jul 4, 2025
2974be0
mixin: Add
Johni0702 Jul 4, 2025
6d25095
stage2/lw: Add builtin support for MixinExtras
Johni0702 Jul 4, 2025
52c525e
stage2/lw: Import third-party mod compatibility patches from Essential
Johni0702 Jul 7, 2025
e73a543
stage2/lw: Fix erroneous "corrupt" jars errors emitted by Forge's Jar…
Johni0702 Jul 8, 2025
c226736
misc: Update README for new LaunchWrapper functionality
Johni0702 Jul 8, 2025
7bb888e
mixin: Release 0.1.0
Johni0702 Jul 8, 2025
81d4a41
stage2: Release 1.7.0
Johni0702 Jul 8, 2025
e0c926f
stage1: Release 11
Johni0702 Jul 8, 2025
e1678e8
stage0: Release 1.3.0
Johni0702 Jul 8, 2025
df4b5a1
build/mixin: Implement merging of class initializers
Johni0702 Jul 14, 2025
c7c07e9
build/mixin: Implement adding fields to target class
Johni0702 Jul 14, 2025
9c8d439
build/mixin: Implement access transformer on shadow methods and fields
Johni0702 Jul 14, 2025
31b5b5c
build/mixin: Handle bridge types in shadow method/field descriptor
Johni0702 Jul 14, 2025
fb8dffe
build/mixin: Support multiple mixins per target class
Johni0702 Jul 14, 2025
88a7b3e
build/mixin: Allow creating new classes
Johni0702 Jul 14, 2025
0faedcb
mixin: Add support for MixinBooter
Johni0702 Jul 14, 2025
225b93f
stage2/lw: Support extracting MixinExtras versions from third-party jars
Johni0702 Jul 14, 2025
e3b6f26
add stage 2 compatibility for FabricLoader subclasses e.g. lunar client
Traben-0 Nov 9, 2025
7365e6f
Revert "add stage 2 compatibility for FabricLoader subclasses e.g. lu…
Traben-0 Nov 9, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 26 additions & 0 deletions .github/workflows/publish-mixin.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Publish mixin

on:
push:
tags:
- mixin/v*

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- uses: actions/setup-java@v4
with:
distribution: temurin
java-version: |
8
16
17

- name: Publish
run: ./gradlew :mixin:publish --stacktrace
env:
ORG_GRADLE_PROJECT_nexus_user: ${{ secrets.NEXUS_USER }}
ORG_GRADLE_PROJECT_nexus_password: ${{ secrets.NEXUS_PASSWORD }}
2 changes: 1 addition & 1 deletion .github/workflows/publish-stage2.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
17

- name: Build
run: ./gradlew :stage2:{launchwrapper,fabric,modlauncher{8,9}}:build --stacktrace
run: ./gradlew :stage2:{launchwrapper-legacy,fabric,modlauncher{8,9}}:build --stacktrace

- name: Upload Artifacts
uses: actions/upload-artifact@v4
Expand Down
119 changes: 118 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1 +1,118 @@
[Docs](https://github.com/EssentialGG/EssentialLoader/tree/master/docs)
## Internals
For an explanation of how the internals of Essential Loader on various platforms function, see the [docs](https://github.com/EssentialGG/EssentialLoader/tree/master/docs) folder.

## Using Essential Loader with your mod on 1.8.9 - 1.12.2
Essential Loader for Minecraft 1.8.9 through 1.12.2 (commonly called "legacy Forge" or "LaunchWrapper") provides support
for Mixin 0.8.x (even on 1.8.9, and with improved third-party mod compatibility on 1.12.2) and Jar-in-Jar style
dependency management (e.g. if two mods ship different versions of the same dependency, it will automatically select
the more recent one).

### Setup
To use it with your mod, firstly you must declare a dependency in your build script and include it in your jar file:
```kotlin
repositories {
maven("https://repo.essential.gg/repository/maven-public/")
}

val embed by configurations.creating
configurations.implementation.get().extendsFrom(embed)

dependencies {
embed("gg.essential:loader-launchwrapper:1.3.0")
}

tasks.jar {
// Embed the contents of the Essential Loader jar into your mod jar.
dependsOn(embed)
from(embed.files.map { zipTree(it) })
// Set Essential Loader as the Tweaker for your mod.
// If you already have a custom Tweaker, you can have it extend the class instead.
// If you previously used the Mixin Tweaker, you can simply use Essential Loader instead, it'll automatically
// initialize Mixin for any mod with a `MixinConfigs` attribute.
manifest.attributes(mapOf("TweakClass" to "gg.essential.loader.stage0.EssentialSetupTweaker"))
}
```
You then need to create a `essential.mod.json` file in your `src/main/resources` folder which defines some metadata and
specifies which libraries your mod includes and where inside the mod jar they can be found:
```json
{
"id": "your_mod_id_goes_here",
"version": "1.0.0",
"jars": [
{
"id": "com.example:examplelib",
"version": "0.1.0",
"file": "META-INF/jars/examplelib-0.1.0.jar"
}
]
}
```
If you don't have any special needs, you can auto-generate the `version` and `jars` entries and automate the inclusion
of the libraries in your mod based on Gradle dependencies with the following snippet in your build script:
```kotlin
val jij by configurations.creating
configurations.implementation.get().extendsFrom(jij)

dependencies {
// Add all the dependencies you wish to jar-in-jar to the custom `jij` configuration
jij("com.example:examplelib:0.1.0")
}

tasks.processResources {
val expansions = mapOf(
"version" to version,
"jars" to provider {
jij.resolvedConfiguration.resolvedArtifacts.joinToString(",\n") { artifact ->
val id = artifact.moduleVersion.id
"""
{
"id": "${id.group}:${id.name}",
"version": "${id.version}",
"file": "META-INF/jars/${artifact.file.name}"
}
""".trimIndent()
}
},
)
inputs.property("expansions", expansions)
filesMatching("essential.mod.json") {
expand(expansions)
}
}

tasks.jar {
dependsOn(jij)
from(jij.files) {
into("META-INF/jars")
}
}
```
and the following `essential.mod.json` template file:
```json
{
"id": "your_mod_id_goes_here",
"version": "${version}",
"jars": [
${jars.get()}
]
}
```

### Mixin 0.8.x

To use our Mixin with your mod, assuming you've already included Essential Loader as per above instructions, and you've
already set up Mixin's annotation processor and refmap generation via your build system (this is done the same way as
it would be done with stock Mixin 0.8.x or 0.7.10, Essential Loader only affects things at runtime), simply
add it as a jar-in-jar dependency:
```kotlin
dependencies {
jij("gg.essential:mixin:0.1.0+mixin.0.8.4")

// MixinExtras may be added in the same way:
// Essential Loader will automatically initialize it for you, no need to call `MixinExtrasBootstrap`.
// `annotationProcessor` is necessary to generate refmaps if your build system does not setup MixinExtras for you.
jij(annotationProcessor("io.github.llamalad7:mixinextras-common:0.4.1")!!)
// or if you've previously used Essential's relocated MixinExtras version:
jij(annotationProcessor("gg.essential.lib:mixinextras:0.4.0")!!)
}
```
2 changes: 2 additions & 0 deletions build-logic/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,6 @@ repositories {

dependencies {
api("gradle.plugin.com.github.johnrengelman:shadow:7.1.2")

implementation("org.ow2.asm:asm-commons:9.3")
}
Loading
Loading