Documentation ¶
Index ¶
- func CleanUpYaml(value string) string
- func CommonSlicePrefix(first []string, second []string) []string
- func GetLineIndentation(line string) string
- func GetLineNumberForDoc(content string, docIndex int) (int, error)
- func GetLineNumberFromMatch(content string, match string, docIndex int) (int, error)
- func GetLineNumberFromYamlPath(content string, path string, docIndex int) (int, error)
- func GetStringInBetween(str, start, end string) string
- func IsLineEmpty(line string) bool
- func IsTarFile(value []byte) bool
- func TryGetLineNumberFromValue(value string) (int, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CleanUpYaml ¶ added in v0.1.0
CleanUpYaml removes lines that only contain comments or are empty also removes trailing comments after the "---" multi doc separator
func CommonSlicePrefix ¶ added in v0.2.0
func GetLineIndentation ¶ added in v0.0.6
func GetLineNumberForDoc ¶
GetLineNumberForDoc returns the line number of the first line of a document (disregards empty lines and comments)
func GetLineNumberFromMatch ¶
GetLineNumberFromMatch returns the line number for a given substring in "content"
func GetLineNumberFromYamlPath ¶
GetLineNumberFromYamlPath returns the line number in a yaml text given the yaml path pass 0 as docIndex in case of a single yaml document
func GetStringInBetween ¶ added in v0.0.8
GetStringInBetween Returns empty string if no start/end string found
func IsLineEmpty ¶ added in v0.0.6
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.