cli

package
v0.11.1 Latest Latest
Warning

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

Go to latest
Published: Jan 18, 2019 License: Apache-2.0 Imports: 13 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddKubectlFlagsToCmd

func AddKubectlFlagsToCmd(cmd *cobra.Command) clientcmd.ClientConfig

AddKubectlFlagsToCmd adds kubectl like flags to a command and returns the ClientConfig interface for retrieving the values.

func AskToProceed added in v0.4.0

func AskToProceed(message string) bool

AskToProceed prompts the user with a message (typically a yes or no question) and returns whether or not they responded in the affirmative or negative.

func NewVersionCmd

func NewVersionCmd(cliName string) *cobra.Command

NewVersionCmd returns a new `version` command to be used as a sub-command to root

func PromptCredentials added in v0.3.2

func PromptCredentials(username, password string) (string, string)

PromptCredentials is a helper to prompt the user for a username and password (unless already supplied)

func PromptMessage added in v0.4.0

func PromptMessage(message, value string) string

PromptMessage prompts the user for a value (unless already supplied)

func PromptPassword added in v0.4.0

func PromptPassword(password string) string

PromptPassword prompts the user for a password, without local echo. (unless already supplied)

func PromptUsername added in v0.4.0

func PromptUsername(username string) string

PromptUsername prompts the user for a username value

func ReadAndConfirmPassword added in v0.11.0

func ReadAndConfirmPassword() (string, error)

ReadAndConfirmPassword is a helper to read and confirm a password from stdin

func SetGLogLevel added in v0.11.0

func SetGLogLevel(glogLevel int)

SetGLogLevel set the glog level for the k8s go-client

func SetLogLevel added in v0.11.0

func SetLogLevel(logLevel string)

SetLogLevel parses and sets a logrus log level

Types

This section is empty.

Jump to

Keyboard shortcuts

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