Skip to content

Commit

Permalink
Fix side arguments not being passed.
Browse files Browse the repository at this point in the history
  • Loading branch information
PhoenixVX committed Dec 11, 2024
1 parent 77268c7 commit 1fe0356
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions cli/src/main/java/org/mcphackers/mcp/main/MainCLI.java
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,9 @@ public MainCLI(String[] args) {
log(new Ansi().fgBrightRed().a("Error: Java Development Kit is required to recompile!").toString());
log("Using Java from " + Paths.get(Util.getJava()).toAbsolutePath());
}
if (Util.getJavaVersion() > 8) {
log("WARNING: JDK " + Util.getJavaVersion() + " is being used! Java 8 is recommended.");
}
if (version != null) log(version);
log(new Ansi().fgDefault().a("Enter a command to execute:").toString());
}
Expand Down Expand Up @@ -144,9 +147,6 @@ public MainCLI(String[] args) {
helpCommand = null;
executeTimes++;
}
if (Util.getJavaVersion() > 8) {
log("WARNING: JDK " + Util.getJavaVersion() + " is being used! Java 8 is recommended.");
}
}

public static void main(String[] args) {
Expand Down Expand Up @@ -242,6 +242,9 @@ private void setParams(Map<String, Object> parsedArgs, TaskMode mode) {
case "server":
side = Side.SERVER;
break;
case "merged":
side = Side.MERGED;
break;
}
if (mode == TaskMode.HELP) {
for (TaskMode taskMode : TaskMode.registeredTasks) {
Expand Down

0 comments on commit 1fe0356

Please sign in to comment.