cmp

package
v0.3.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 13, 2019 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Handlers = CompletionHandlers{}

Handlers are global Handlers to be used in annotations

Functions

func Create

func Create(root *cobra.Command) complete.Command

Create parses a *cobra.Command into a complete.Command

Types

type CompletionHandlers

type CompletionHandlers map[string]complete.Predictor

CompletionHandlers is a set of predictors

func (CompletionHandlers) Add

Add adds a predictor to the list of handlers

func (CompletionHandlers) Get

Get returns a predictor from the list of handlers

func (CompletionHandlers) GetOrNone

GetOrNone returns a predictor in case it exists, otherwise complete.PredictNothing

func (CompletionHandlers) Has

func (h CompletionHandlers) Has(k string) bool

Has returns whether a predictor exists

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL