Skip to content

Commit

Permalink
Add directly to settings.getEnvironmentVariables()
Browse files Browse the repository at this point in the history
  • Loading branch information
shedaniel committed Oct 24, 2023
1 parent 329bd92 commit f5e9e4a
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -58,13 +58,13 @@ public void applyTo(RunConfigSettings settings, ConfigValue.Resolver configValue

settings.vmArgs(CollectionUtil.map(jvmArgs, value -> value.resolve(configValueResolver)));

// Add MOD_CLASSES, this is something that ForgeGradle does
env.computeIfAbsent("MOD_CLASSES", $ -> ConfigValue.of("{source_roots}"));

env.forEach((key, value) -> {
String resolved = value.resolve(configValueResolver);
settings.getEnvironmentVariables().putIfAbsent(key, resolved);
});

// Add MOD_CLASSES, this is something that ForgeGradle does
settings.getEnvironmentVariables().computeIfAbsent("MOD_CLASSES", $ -> ConfigValue.of("{source_roots}").resolve(configValueResolver));
}

public static ForgeRunTemplate fromJson(JsonObject json) {
Expand Down

0 comments on commit f5e9e4a

Please sign in to comment.