From 3839c00ae2f132b115ffabec500ddba2a536527e Mon Sep 17 00:00:00 2001 From: Valentin Rothberg Date: Thu, 30 Aug 2018 19:31:05 +0200 Subject: don't print help message for usage errors Don't print potentially verbose help messages in case of usage errors, but print only the usage error followed by a pointer to the command's help. This aligns with Docker. ``` $ podman run -h flag needs an argument: -h See 'podman run --help'. ``` Signed-off-by: Valentin Rothberg Closes: #1379 Approved by: rhatdan --- cmd/podman/unpause.go | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'cmd/podman/unpause.go') diff --git a/cmd/podman/unpause.go b/cmd/podman/unpause.go index d5b2732af..d4e2605cb 100644 --- a/cmd/podman/unpause.go +++ b/cmd/podman/unpause.go @@ -16,11 +16,12 @@ var ( Unpauses one or more running containers. The container name or ID can be used. ` unpauseCommand = cli.Command{ - Name: "unpause", - Usage: "Unpause the processes in one or more containers", - Description: unpauseDescription, - Action: unpauseCmd, - ArgsUsage: "CONTAINER-NAME [CONTAINER-NAME ...]", + Name: "unpause", + Usage: "Unpause the processes in one or more containers", + Description: unpauseDescription, + Action: unpauseCmd, + ArgsUsage: "CONTAINER-NAME [CONTAINER-NAME ...]", + OnUsageError: usageErrorHandler, } ) -- cgit v1.2.3-54-g00ecf