Documentation
¶
Index ¶
- func ExpandPath(p string) string
- func HashString(s string) (string, error)
- func SanitizeString(s string) string
- func StringSlicesEqual(l, r []string) bool
- func StringSlicesEqualIgnoreOrder(l, r []string) bool
- func YAMLToJSON(yamlBytes []byte) ([]byte, error)
- func YamlMarshal(o interface{}) ([]byte, error)
- func YamlUnmarshal(yamlBytes []byte, dest interface{}) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ExpandPath ¶
func ExpandPath(p string) string
ExpandPath replaces common path aliases: ~ -> $HOME
func HashString ¶ added in v1.15.1
func HashString(s string) (string, error)
HashString Takes String and returns a sha1 hash represented as a string
func SanitizeString ¶
func SanitizeString(s string) string
SanitizeString iterated a strings and removes any characters not in the allow list
func StringSlicesEqual ¶
func StringSlicesEqual(l, r []string) bool
func StringSlicesEqualIgnoreOrder ¶
func StringSlicesEqualIgnoreOrder(l, r []string) bool
func YAMLToJSON ¶ added in v1.10.0
func YAMLToJSON(yamlBytes []byte) ([]byte, error)
YAMLToJSON converts yaml to json
func YamlMarshal ¶
func YamlMarshal(o interface{}) ([]byte, error)
YamlMarshal tries to marshal the input struct into yaml content
func YamlUnmarshal ¶
func YamlUnmarshal(yamlBytes []byte, dest interface{}) error
YamlUnmarshal unmarshals the yaml content to an interface
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.