diff --git a/cmd/haulerctl/app/copy.go b/cmd/haulerctl/app/copy.go index dc85008..73fad58 100644 --- a/cmd/haulerctl/app/copy.go +++ b/cmd/haulerctl/app/copy.go @@ -30,7 +30,7 @@ func NewCopyCommand() *cobra.Command { f := cmd.Flags() f.StringVarP(&opts.dir, "dir", "d", ".", "Target directory for file copy") - f.StringVarP(&opts.src, "registry", "r", "myregistry:5000", "Registry URL to copy file from") + f.StringVarP(&opts.src, "registry", "r", "localhost:5000/file:test", "URI for object in the registry") return cmd } diff --git a/cmd/haulerctl/app/root.go b/cmd/haulerctl/app/root.go index e36f7ae..96bb46a 100644 --- a/cmd/haulerctl/app/root.go +++ b/cmd/haulerctl/app/root.go @@ -30,7 +30,7 @@ var ( haulerctl bundle artifacts haulerctl relocate artifacts haulerctl relocate images - haulerctl copy + haulerctl copy haulerctl create haulerctl bootstrap` ) @@ -38,10 +38,11 @@ var ( // NewRootCommand defines the root haulerctl command func NewRootCommand() *cobra.Command { cmd := &cobra.Command{ - Use: "haulerctl", - Short: "haulerctl provides CLI-based air-gap migration assistance", - Long: getLong, - Example: getExample, + Use: "haulerctl", + Short: "haulerctl provides CLI-based air-gap migration assistance", + Long: getLong, + Example: getExample, + SilenceUsage: true, PersistentPreRunE: func(cmd *cobra.Command, args []string) error { if err := setupLogger(os.Stdout, loglevel); err != nil { return err diff --git a/pkg/copy/copy.go b/pkg/copy/copy.go index 60acfad..7ab1ca3 100644 --- a/pkg/copy/copy.go +++ b/pkg/copy/copy.go @@ -57,7 +57,7 @@ func (c Copier) Get(ctx context.Context, src string) error { resolver := docker.NewResolver(docker.ResolverOptions{}) // Pull file(s) from registry and save to disk - fmt.Printf("Pulling from %s and saving to %s...\n", src, c.Dir) + fmt.Printf("Pulling from %s and saving to %s\n", src, c.Dir) allowedMediaTypes := []string{(c.mediaType)} desc, _, err := oras.Pull(ctx, resolver, src, c.fileStore, oras.WithAllowedMediaTypes(allowedMediaTypes))