Skip to content

Commit

Permalink
Fix incorrect argument use
Browse files Browse the repository at this point in the history
  • Loading branch information
angrycub committed Oct 23, 2023
1 parent b4804d4 commit 09e24ea
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions internal/cli/generate_registry.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,12 +32,12 @@ func (c *GenerateRegistryCommand) Run(args []string) int {
return 1
}

c.cfg.PackName = c.args[0]
c.cfg.RegistryName = c.args[0]

// Generate our UI error context.
errorContext := errors.NewUIErrorContext()

errorContext.Add(errors.UIContextPrefixRegistryName, c.cfg.PackName)
errorContext.Add(errors.UIContextPrefixRegistryName, c.cfg.RegistryName)
errorContext.Add(errors.UIContextPrefixOutputPath, c.cfg.OutPath)

err := creator.CreateRegistry(c.cfg)
Expand Down Expand Up @@ -89,7 +89,6 @@ func (c *GenerateRegistryCommand) Help() string {
c.Example = `
# Create a new registry named "my-new-registry" in the current directory.
nomad-pack generate registry my-new-registry
`
return formatHelp(`
Usage: nomad-pack generate registry <name>
Expand Down

0 comments on commit 09e24ea

Please sign in to comment.