mirror of
https://github.com/containers/skopeo.git
synced 2025-05-09 00:16:23 +00:00
Update for cobra API change
This is not _really_ necessary, but let's be consistent with cobra's style. Signed-off-by: Miloslav Trmač <mitr@redhat.com>
This commit is contained in:
parent
9d73060a2e
commit
c7aaed7397
@ -7,9 +7,9 @@ import (
|
|||||||
)
|
)
|
||||||
|
|
||||||
// autocompleteSupportedTransports list all supported transports with the colon suffix.
|
// autocompleteSupportedTransports list all supported transports with the colon suffix.
|
||||||
func autocompleteSupportedTransports(cmd *cobra.Command, args []string, toComplete string) ([]string, cobra.ShellCompDirective) {
|
func autocompleteSupportedTransports(cmd *cobra.Command, args []string, toComplete string) ([]cobra.Completion, cobra.ShellCompDirective) {
|
||||||
tps := transports.ListNames()
|
tps := transports.ListNames()
|
||||||
suggestions := make([]string, 0, len(tps))
|
suggestions := make([]cobra.Completion, 0, len(tps))
|
||||||
for _, tp := range tps {
|
for _, tp := range tps {
|
||||||
// ListNames is generally expected to filter out deprecated transports.
|
// ListNames is generally expected to filter out deprecated transports.
|
||||||
// tarball: is not deprecated, but it is only usable from a Go caller (using tarball.ConfigUpdater),
|
// tarball: is not deprecated, but it is only usable from a Go caller (using tarball.ConfigUpdater),
|
||||||
|
Loading…
Reference in New Issue
Block a user