adonisjs / env

Framework agnostic environment variables parser and validator
https://docs.adonisjs.com/guides/environment-variables
MIT License
35 stars 10 forks source link

Environment variable's value can not contain dollar '$' sign as first character #32

Closed emmsdan closed 2 years ago

emmsdan commented 2 years ago

Adding a dollar sign $ as the first character in your .env file breaks the process. The only way I could find to bypass this was not to validate it inside env.ts file.

Package version

v3.0.9

Node.js and npm version

node v16.13.2 (npm v8.1.2)

Sample Code (to reproduce the issue)

SOME_ENV_VALUE=$tart_value_with_dollar_sign

A sample repo to reproduce the issue

TEST REPO

Julien-R44 commented 2 years ago

Hello

This is intended, take a look here : https://docs.adonisjs.com/guides/environment-variables#variable-substitution