class Dotenv::Environment
A ‘.env` file that will be read and parsed into a Hash
def initialize(filename, overwrite: false)
-
overwrite
(Boolean
) -- whether the parser should assume existing values will be overwritten -
filename
(String
) -- the path to the file to read
def initialize(filename, overwrite: false) super() @filename = filename @overwrite = overwrite load end
def load
def load update Parser.call(read, overwrite: overwrite) end
def read
def read File.open(@filename, "rb:bom|utf-8", &:read) end