Skip to content

Commit

Permalink
[apache#5807] improvement(CLI): Add functionality to display help inf…
Browse files Browse the repository at this point in the history
…ormation when no args are passed

Add functionality to display help information when no arguments are passed, e.g., gcli
  • Loading branch information
Abyss-lord committed Dec 11, 2024
1 parent 2d160d1 commit e90101d
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions clients/cli/src/main/java/org/apache/gravitino/cli/Main.java
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,10 @@ public class Main {
public static void main(String[] args) {
CommandLineParser parser = new DefaultParser();
Options options = new GravitinoOptions().options();
if (args.length == 0) {
GravitinoCommandLine.displayHelp(options);
return;
}

try {
CommandLine line = parser.parse(options, args);
Expand Down

0 comments on commit e90101d

Please sign in to comment.