Skip to content

Commit

Permalink
Better handling of archive name with wildcards that matches with no file
Browse files Browse the repository at this point in the history
Fixes #266
  • Loading branch information
simulot committed May 28, 2024
1 parent 3549bd8 commit de0b458
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion cmd/upload/upload.go
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,9 @@ func UploadCommand(ctx context.Context, common *cmd.SharedFlags, args []string)
if err != nil {
return err
}
if len(app.fsyss) == 0 {
return nil
}
return app.run(ctx)
}

Expand Down Expand Up @@ -182,7 +185,10 @@ func newCommand(ctx context.Context, common *cmd.SharedFlags, args []string) (*U
if err != nil {
return nil, err
}

if len(app.fsyss) == 0 {
fmt.Println("No file found matching the pattern: ", strings.Join(cmd.Args(), ","))
app.Log.Info("No file found matching the pattern: " + strings.Join(cmd.Args(), ","))
}
return &app, nil
}

Expand Down

0 comments on commit de0b458

Please sign in to comment.