summaryrefslogtreecommitdiff
path: root/cmd/podman/images/import.go
diff options
context:
space:
mode:
authorOpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com>2020-12-09 14:47:05 -0500
committerGitHub <noreply@github.com>2020-12-09 14:47:05 -0500
commitda062b5bd03dd88060eb91c7d02936d5e7427cb9 (patch)
tree4b61e35336b54b815e0cf844778eb8e29906a120 /cmd/podman/images/import.go
parent9abbe0728c5050914168a154622087a4dacd4dfe (diff)
parent2870a0b0a6b94528b82df7cee57c8c6a0252fc85 (diff)
downloadpodman-da062b5bd03dd88060eb91c7d02936d5e7427cb9.tar.gz
podman-da062b5bd03dd88060eb91c7d02936d5e7427cb9.tar.bz2
podman-da062b5bd03dd88060eb91c7d02936d5e7427cb9.zip
Merge pull request #8635 from Luap99/shell-completion-test
Add system test for shell completion
Diffstat (limited to 'cmd/podman/images/import.go')
-rw-r--r--cmd/podman/images/import.go5
1 files changed, 3 insertions, 2 deletions
diff --git a/cmd/podman/images/import.go b/cmd/podman/images/import.go
index f38ab3b19..ac59935ad 100644
--- a/cmd/podman/images/import.go
+++ b/cmd/podman/images/import.go
@@ -25,18 +25,19 @@ var (
Short: "Import a tarball to create a filesystem image",
Long: importDescription,
RunE: importCon,
- ValidArgsFunction: completion.AutocompleteDefault,
+ Args: cobra.RangeArgs(1, 2),
+ ValidArgsFunction: common.AutocompleteDefaultOneArg,
Example: `podman import http://example.com/ctr.tar url-image
cat ctr.tar | podman -q import --message "importing the ctr.tar tarball" - image-imported
cat ctr.tar | podman import -`,
}
imageImportCommand = &cobra.Command{
- Args: cobra.MinimumNArgs(1),
Use: importCommand.Use,
Short: importCommand.Short,
Long: importCommand.Long,
RunE: importCommand.RunE,
+ Args: importCommand.Args,
ValidArgsFunction: importCommand.ValidArgsFunction,
Example: `podman image import http://example.com/ctr.tar url-image
cat ctr.tar | podman -q image import --message "importing the ctr.tar tarball" - image-imported