libstring

package
v4.3.2+incompatible Latest Latest
Warning

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

Go to latest
Published: Oct 31, 2016 License: MIT Imports: 7 Imported by: 3

Documentation

Overview

Package libstring provides string related library functions.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ExpandTilde

func ExpandTilde(path string) string

ExpandTilde is a convenience function that expands ~ to full path.

func ExpandTildeAndEnv

func ExpandTildeAndEnv(path string) string

ExpandTilde is a convenience function that expands both ~ and $ENV.

func FlattenPhone

func FlattenPhone(phone string) string

FlattenPhone removes non-number characters from phone number.

func GeneratePassword

func GeneratePassword(size int) (string, error)

GeneratePassword returns password. size determines length of initial seed bytes.

func JSONToText

func JSONToText(input string) string

func PrettyPrintJSON

func PrettyPrintJSON(jsonBytes []byte) ([]byte, error)

PrettyPrintJSON indents JSON nicely.

func StripChars

func StripChars(str, chr string) string

StripChars removes multiple characters in a string.

Types

This section is empty.

Jump to

Keyboard shortcuts

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