Documentation
¶
Overview ¶
Package dotenv parses the subset of .env syntax `notenv import` accepts. The dialect is documented and deliberately small — an importer for secrets must never guess:
- blank lines and full-line `#` comments are skipped; an unquoted value may carry a trailing comment when whitespace precedes the `#`
- an optional `export ` prefix is dropped
- unquoted values are trimmed of surrounding whitespace
- single-quoted values are literal, double-quoted values understand the \n, \t, \", \\ escapes; both may span multiple lines
- there is no variable expansion of any kind: a secrets file is not a shell script, and silently expanding `$X` would corrupt real values
Anything else — a line without `=`, an unterminated quote, a stray escape — fails the parse with its line number, so an import is all-or-nothing.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
Click to show internal directories.
Click to hide internal directories.