Skip to content
Permalink
Browse files
display nice error if argument is omitted
  • Loading branch information
ahgittin committed Apr 24, 2017
1 parent e974f73 commit d2203982604ede161d87b8ae7d4ba0ad657bcf91
Showing 1 changed file with 3 additions and 0 deletions.
@@ -48,6 +48,9 @@ func (cmd *CatalogAdd) Metadata() command_metadata.CommandMetadata {
}

func (cmd *CatalogAdd) Run(scope scope.Scope, c *cli.Context) {
if c.Args().First() == "" {
error_handler.ErrorExit("A filename or URL must be provided as the first argument", error_handler.CLIUsageErrorExitCode)
}
if err := net.VerifyLoginURL(cmd.network); err != nil {
error_handler.ErrorExit(err)
}

0 comments on commit d220398

Please sign in to comment.