Skip to content

Commit

Permalink
Version 0.0.1
Browse files Browse the repository at this point in the history
  • Loading branch information
LlamaLad7 committed Jan 6, 2022
1 parent 375adcd commit 18abc25
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 7 deletions.
15 changes: 15 additions & 0 deletions README.MD
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# MixinExtras

A small companion library to [Mixin](https://github.com/SpongePowered/Mixin/), designed to help you write your Mixins in
a more expressive and compatible way.

More information about each feature offered can be found at the [Wiki](https://github.com/LlamaLad7/MixinExtras/wiki).

## Setup
For the time being, I recommend depending on this library via [JitPack](https://jitpack.io/).
After adding its repository to your build script, you can depend on it like so
```gradle
dependencies {
implementation("com.github.LlamaLad7:MixinExtras:0.0.1")
}
```
9 changes: 4 additions & 5 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -4,25 +4,24 @@ plugins {
}

group = "com.llamalad7"
version = "1.0-SNAPSHOT"
version = "0.0.1"

repositories {
mavenCentral()
maven("https://repo.spongepowered.org/maven")
}

dependencies {
implementation("org.spongepowered:mixin:0.8.5")
implementation("org.apache.commons:commons-lang3:3.3.2")
implementation("org.ow2.asm:asm-debug-all:5.2")
compileOnly("org.spongepowered:mixin:0.8.5")
compileOnly("org.apache.commons:commons-lang3:3.3.2")
compileOnly("org.ow2.asm:asm-debug-all:5.2")
}

publishing {
publications {
create<MavenPublication>("maven") {
groupId = "com.llamalad7"
artifactId = "MixinExtras"
version = "1.0-SNAPSHOT"

from(components["java"])
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,14 @@
import org.spongepowered.asm.mixin.injection.struct.InjectionInfo;

public class MixinExtrasBootstrap {
private static boolean initialized = false;

public static void init() {
InjectionInfo.register(ModifyExpressionValueInjectionInfo.class);
InjectionInfo.register(WrapWithConditionInjectionInfo.class);
if (!initialized) {
initialized = true;

InjectionInfo.register(ModifyExpressionValueInjectionInfo.class);
InjectionInfo.register(WrapWithConditionInjectionInfo.class);
}
}
}

0 comments on commit 18abc25

Please sign in to comment.