Documentation
¶
Index ¶
- func ClearAPIKey() error
- func ConfirmWithPIN(message string) error
- func CopyToClipboard(text string) error
- func FileExists(path string) bool
- func GeneratePIN() (string, error)
- func GeneratePassword(length int) (string, error)
- func GeneratePasswordByType(length int, passwordType string) (string, error)
- func GetAPIKey() (string, error)
- func GetConfigDir() (string, error)
- func HashFile(filePath, algorithm string) (string, error)
- func HashString(input, algorithm string) (string, error)
- func PromptInput(message string) (string, error)
- func PromptMultiSelect(message string, options []string) ([]string, error)
- func PromptSelect(message string, options []string) (string, error)
- func ReadFile(path string) (string, error)
- func StoreAPIKey(apiKey string) error
- func SurveyConfirm(message string, defaultValue bool) (bool, error)
- func SurveyInput(message string, defaultValue string) (string, error)
- func SurveyMultiline(message string) (string, error)
- func SurveyPassword(message string) (string, error)
- func WriteFile(path, content string) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ClearAPIKey ¶ added in v0.5.0
func ClearAPIKey() error
ClearAPIKey removes the stored Gemini API key
func ConfirmWithPIN ¶ added in v1.1.0
ConfirmWithPIN generates a PIN, displays it, and asks the user to confirm by entering it.
func CopyToClipboard ¶ added in v0.3.0
CopyToClipboard copies text to clipboard
func GeneratePIN ¶ added in v0.6.0
GeneratePIN generates a random 6-digit PIN
func GeneratePassword ¶
GeneratePassword generates a random password of the specified length
func GeneratePasswordByType ¶ added in v0.3.0
GeneratePasswordByType generates a password based on type
func GetConfigDir ¶ added in v0.5.0
GetConfigDir returns the directory for storing mayrlabs configuration
func HashString ¶
HashString generates a hash of the input string using the specified algorithm. MD5 and SHA1 are supported for legacy compatibility but SHA256 is recommended. #nosec G401 - MD5/SHA1 are intentionally supported as user options
func PromptInput ¶
PromptInput prompts the user for input with a message (legacy version)
func PromptMultiSelect ¶ added in v0.6.0
PromptMultiSelect prompts the user to select multiple items from a list
func PromptSelect ¶ added in v0.3.0
PromptSelect prompts the user to select from a list of options
func StoreAPIKey ¶ added in v0.5.0
StoreAPIKey stores the Gemini API key securely
func SurveyConfirm ¶ added in v0.4.0
SurveyConfirm prompts the user for a yes/no confirmation
func SurveyInput ¶ added in v0.4.0
SurveyInput prompts the user for input using survey
func SurveyMultiline ¶ added in v0.5.0
SurveyMultiline prompts the user for multiline input
func SurveyPassword ¶ added in v0.5.0
SurveyPassword prompts the user for a password input
Types ¶
This section is empty.