ioutils

package
v2.47.3 Latest Latest
Warning

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

Go to latest
Published: Dec 11, 2023 License: Apache-2.0 Imports: 13 Imported by: 5

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DoubleWinPathSeparator

func DoubleWinPathSeparator(filePath string) string

func PromptStrings

func PromptStrings(items []PromptItem, label string, onSelect func(PromptItem)) error

Prompt strings by selecting from list until "Save and continue" is selected. Usage example: 🐸 Save and continue JFrog Artifactory URL (http://localhost:8080/artifactory/) JFrog Distribution URL () JFrog Xray URL () JFrog Mission Control URL () JFrog Pipelines URL ()

func ReadCredentialsFromConsole

func ReadCredentialsFromConsole(details, savedDetails coreutils.Credentials, disallowUsingSavedPassword bool) error

disallowUsingSavedPassword - Prevent changing username or url without changing the password. False if the user changed the username or the url.

func ScanFromConsole

func ScanFromConsole(caption string, scanInto *string, defaultValue string)

func ScanJFrogPasswordFromConsole added in v2.14.0

func ScanJFrogPasswordFromConsole() (string, error)

func ScanPasswordFromConsole added in v2.2.0

func ScanPasswordFromConsole(message string) (string, error)

func SelectString

func SelectString(items []PromptItem, label string, needSearch bool, onSelect func(PromptItem)) error

func UnixToWinPathSeparator

func UnixToWinPathSeparator(filePath string) string

func WinToUnixPathSeparator

func WinToUnixPathSeparator(filePath string) string

Types

type PromptItem

type PromptItem struct {
	// The option string to show, i.e - JFrog Artifactory URL.
	Option string
	// The variable to set.
	TargetValue *string
	// Default value to show. If empty string is entered, use the default value.
	DefaultValue string
}

Jump to

Keyboard shortcuts

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