Merge pull request #8096 from helen-frank/feature/ctrVersionAddArgsCheck

ctr version: add args check
This commit is contained in:
Derek McGowan
2023-02-15 15:29:01 -08:00
committed by GitHub

View File

@@ -30,6 +30,10 @@ var Command = cli.Command{
Name: "version",
Usage: "Print the client and server versions",
Action: func(context *cli.Context) error {
if context.NArg() != 0 {
return fmt.Errorf("extra arguments: %v", context.Args())
}
fmt.Println("Client:")
fmt.Println(" Version: ", version.Version)
fmt.Println(" Revision:", version.Revision)