Skip to content

Commit ae07822

Browse files
committed
merge branch 'pr-1129'
LGTMs: @mrunalp @cyphar Closes #1129
2 parents 4ec570d + ba1c0b4 commit ae07822

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

create.go

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
package main
22

33
import (
4+
"fmt"
45
"os"
56

67
"github.com/urfave/cli"
@@ -48,6 +49,11 @@ command(s) that get executed on start, edit the args parameter of the spec. See
4849
},
4950
},
5051
Action: func(context *cli.Context) error {
52+
if context.NArg() != 1 {
53+
fmt.Printf("Incorrect Usage.\n\n")
54+
cli.ShowCommandHelp(context, "create")
55+
return fmt.Errorf("runc: \"create\" requires exactly one argument")
56+
}
5157
spec, err := setupSpec(context)
5258
if err != nil {
5359
return err

0 commit comments

Comments
 (0)