Module

Dotenv.Internal.Parse

Package
purescript-dotenv
Repository
nicholassaunders/purescript-dotenv

This module encapsulates the parsing logic for a .env file.

#newlineChars Source

newlineChars :: Array Char

Newline characters (carriage return / line feed)

#whitespaceChars Source

whitespaceChars :: Array Char

Whitespace characters (excluding newline characters)

#settings Source

settings :: Parser String (Array (Setting UnresolvedValue))

Parses .env settings.

#comment Source

comment :: Parser String String

Parses a comment in the form of # Comment.

#name Source

name :: Parser String Name

Parses a setting name.

#variableSubstitution Source

variableSubstitution :: Parser String UnresolvedValue

Parses a variable substitution, i.e. ${VARIABLE_NAME}.

#commandSubstitution Source

commandSubstitution :: Parser String UnresolvedValue

Parses a command substitution, i.e. $(whoami).

#quotedValue Source

quotedValue :: Char -> Parser String UnresolvedValue

Parses a quoted value, enclosed in the specified type of quotation mark.

#unquotedValue Source

unquotedValue :: Parser String UnresolvedValue

Parses an unquoted value.

#valueFromValues Source

valueFromValues :: Array UnresolvedValue -> UnresolvedValue

Assembles a single value from a series of values.

#value Source

value :: Parser String UnresolvedValue

Parses a setting value.

#setting Source

setting :: Parser String (Setting UnresolvedValue)

Parses a setting in the form of NAME=value.