helpers

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Nov 8, 2020 License: MPL-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ConfigDirectory = func() string {
		userHomeDir, err := os.UserHomeDir()
		QuitWithMessageIfErr(err, "Unable to locate user's home directory.")
		return path.Join(userHomeDir, ".config", "lightOtp")
	}()
)

Functions

func CheckErr

func CheckErr(err error)

func CollectCensoredInput

func CollectCensoredInput() string

func ErrWithMessage

func ErrWithMessage(err error, message string)

func LoadCodes

func LoadCodes() error

func NewSettings

func NewSettings() models.Settings

func OpenConfigFile

func OpenConfigFile(fname string) (string, string, error)

func PrintDebugLn

func PrintDebugLn(message string)

func PrintErrLn

func PrintErrLn(message string)

func PrintInfoLn

func PrintInfoLn(message string)

func QuitWithMessageIfErr

func QuitWithMessageIfErr(err error, message string)

func SetupConfigDir

func SetupConfigDir()

func UpdateCodes

func UpdateCodes() error

Types

This section is empty.

Jump to

Keyboard shortcuts

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