Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func IsFileAccessError ¶
func IsParseError ¶
func ParseFiles ¶
ParseFiles parses the provided files and returns the variables parsed.
Types ¶
type FileAccessError ¶
func (*FileAccessError) Error ¶
func (e *FileAccessError) Error() string
func (*FileAccessError) Unwrap ¶
func (e *FileAccessError) Unwrap() error
type ParseError ¶
type ParseError struct {
Content string `json:"content"`
Line int `json:"line"`
Column int `json:"column"`
Err error `json:"error"`
}
func (*ParseError) Error ¶
func (e *ParseError) Error() string
func (*ParseError) Unwrap ¶
func (e *ParseError) Unwrap() error
type Parser ¶
type Parser struct {
// contains filtered or unexported fields
}
Parser is a parser for dotenv files.
func (*Parser) ExpandVariables ¶
ExpandVariables resolves ${VAR} references in the variables parsed by the Parser. ${VAR} format can be replaced in combination with any other mixed text, however, $VAR will only be replace if that's the entire value, e.g. "FOO=$VAR". Additionally, $VAR/${VAR} references in single quotes will not be replaced, which includes triple-single quote blocks.
Click to show internal directories.
Click to hide internal directories.