From 0e2c85d6358ffa2a440c56355bff9cda4bf9f865 Mon Sep 17 00:00:00 2001 From: Willy Kloucek Date: Wed, 4 May 2022 08:50:36 +0200 Subject: [PATCH] fix nats command naming --- ocis/pkg/command/natsserver.go | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/ocis/pkg/command/natsserver.go b/ocis/pkg/command/natsserver.go index 17fa6023ed..b021172064 100644 --- a/ocis/pkg/command/natsserver.go +++ b/ocis/pkg/command/natsserver.go @@ -10,11 +10,11 @@ import ( "github.com/urfave/cli/v2" ) -// NatsServerCommand is the entrypoint for the nats server command. -func NatsServerCommand(cfg *config.Config) *cli.Command { +// NatsCommand is the entrypoint for the Nats command. +func NatsCommand(cfg *config.Config) *cli.Command { return &cli.Command{ - Name: "nats-server", - Usage: "start nats server", + Name: cfg.Nats.Service.Name, + Usage: subcommandDescription(cfg.Nats.Service.Name), Category: "extensions", Before: func(c *cli.Context) error { if err := parser.ParseConfig(cfg); err != nil { @@ -29,5 +29,5 @@ func NatsServerCommand(cfg *config.Config) *cli.Command { } func init() { - register.AddCommand(NatsServerCommand) + register.AddCommand(NatsCommand) }