uitools

package
v0.0.0-...-40d5209 Latest Latest
Warning

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

Go to latest
Published: Feb 7, 2022 License: MIT Imports: 4 Imported by: 0

Documentation

Overview

Package uitools contains helper utils for CLI UI.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func InputString

func InputString(msg string) (string, error)

InputString waits user input on stdin and returns it without new line symbol.

func InputStringWithDefault

func InputStringWithDefault(msg string, defaultValue string) (string, error)

InputStringWithDefault calls InputString and returns defaultValue if InputString has finished without error and has return empty string.

func InputYesNo

func InputYesNo(msg string, yesByDefault bool) (bool, error)

InputYesNo waits on stdin user answer to Yes/No question. Returns true on yes and false on no.

Types

This section is empty.

Jump to

Keyboard shortcuts

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