Parse Args for dolt admin show-root

The command doesn't have any args, but parsing them will make --help work.
This commit is contained in:
Nick Tobey
2023-04-14 10:11:01 -07:00
parent 81fa002f5b
commit 9c3525aa85
+5
View File
@@ -61,6 +61,11 @@ func (cmd ShowRootCmd) Hidden() bool {
// Version displays the version of the running dolt client
// Exec executes the command
func (cmd ShowRootCmd) Exec(ctx context.Context, commandStr string, args []string, dEnv *env.DoltEnv) int {
ap := cmd.ArgParser()
usage, _ := cli.HelpAndUsagePrinters(cli.CommandDocsForCommandString(commandStr, cli.CommandDocumentationContent{}, ap))
cli.ParseArgsOrDie(ap, args, usage)
db := doltdb.HackDatasDatabaseFromDoltDB(dEnv.DoltDB)
dss, err := db.Datasets(ctx)
if err != nil {