Skip to content

Commit

Permalink
Added descriptions to program args
Browse files Browse the repository at this point in the history
  • Loading branch information
Caedis committed Jan 4, 2025
1 parent 59de885 commit 540ea88
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/main/java/GTNHNightlyUpdater/Main.java
Original file line number Diff line number Diff line change
Expand Up @@ -90,14 +90,14 @@ private static Set<String> getModExclusions(Path cacheDir) throws IOException {

@ToString
static class Options {
@CommandLine.Option(names = {"-l", "--latest"})
@CommandLine.Option(names = {"-l", "--latest"}, description = "Use the latest version of GTNH org mods instead of the latest nightly.")
private boolean useLatest = false;

@CommandLine.ArgGroup(exclusive = false, multiplicity = "0..*")
List<Instance> instances;

static class Instance {
@CommandLine.Option(names = "--add", required = true)
@CommandLine.Option(names = "--add", required = true, description = "Used to add instances to be updated; Allows for updating a client and server at the same time.")
boolean add_instance; // leave this for the option

@CommandLine.ArgGroup(exclusive = false, multiplicity = "1")
Expand All @@ -109,7 +109,7 @@ static class InstanceConfig {
@CommandLine.Spec
CommandLine.Model.CommandSpec spec;

@CommandLine.Option(names = {"-m", "--minecraft"}, required = true)
@CommandLine.Option(names = {"-m", "--minecraft"}, required = true, description = "Path to the base minecraft folder to be updated (it contains the mods and config folder).")
void setMinecraftDir(String value) {
val path = Path.of(value);
if (!Files.exists(path)) {
Expand All @@ -118,7 +118,7 @@ void setMinecraftDir(String value) {
this.minecraftDir = path;
}

@CommandLine.Option(names = {"-s", "--side"}, required = true, description = "Valid values: ${COMPLETION-CANDIDATES}")
@CommandLine.Option(names = {"-s", "--side"}, required = true, description = "Denotes the mods that should be used; Valid values: ${COMPLETION-CANDIDATES}")
@Getter
Side side;

Expand All @@ -127,7 +127,7 @@ enum Side {
SERVER
}

@CommandLine.Option(names = {"-S", "--symlinks"})
@CommandLine.Option(names = {"-S", "--symlinks"}, description = "Use symlinks instead of copying files to the mods directory; Mac/Linux only. Must be on the same filesystem.")
@Getter
private boolean useSymlinks = false;
}
Expand Down

0 comments on commit 540ea88

Please sign in to comment.