Skip to content

Commit 691509a

Browse files
committed
update README
1 parent 762826c commit 691509a

File tree

1 file changed

+11
-9
lines changed

1 file changed

+11
-9
lines changed

README.md

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -533,18 +533,16 @@ Override any environment variables that have already been set.
533533

534534
## FAQ
535535

536-
<details><summary>What about variable expansion?</summary><br/>
536+
<details><summary>Should I commit my `.env` file?</summary><br/>
537537

538-
Try [dotenv-expand](https://github.com/motdotla/dotenv-expand)
538+
No.
539539

540-
</details>
541-
<details><summary>Should I commit my `.env` file?</summary><br/>
540+
Unless you encrypt it with [dotenvx](https://github.com/dotenvx/dotenvx). Then we recommend you do.
542541

543-
No. We **strongly** recommend against committing your `.env` file to version
542+
</details>
543+
<details><summary>What about variable expansion?</summary><br/>
544544

545-
control. It should only include environment-specific values such as database
546-
passwords or API keys. Your production database should have a different
547-
password than your development database.
545+
Use [dotenvx](https://github.com/dotenvx/dotenvx).
548546

549547
</details>
550548
<details><summary>How do I use dotenv with `import`?</summary><br/>
@@ -611,6 +609,9 @@ We recommend creating one `.env` file per environment. Use `.env` for local/deve
611609
> In a twelve-factor app, env vars are granular controls, each fully orthogonal to other env vars. They are never grouped together as “environments”, but instead are independently managed for each deploy. This is a model that scales up smoothly as the app naturally expands into more deploys over its lifetime.
612610
>
613611
> [The Twelve-Factor App](http://12factor.net/config)
612+
613+
Additionally, we recommend using [dotenvx](https://github.com/dotenvx/dotenvx) to encrypt and manage these.
614+
614615
</details>
615616
<details><summary>Can I customize/write plugins for dotenv?</summary><br/>
616617

@@ -622,6 +623,7 @@ const variableExpansion = require('dotenv-expand')
622623
const myEnv = dotenv.config()
623624
variableExpansion(myEnv)
624625
```
626+
625627
</details>
626628
<details><summary>What rules does the parsing engine follow?</summary><br/>
627629

@@ -656,7 +658,7 @@ Use [dotenvx](https://github.com/dotenvx/dotenvx) to unlock syncing encrypted .e
656658
Remove it, [remove git history](https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/removing-sensitive-data-from-a-repository) and then install the [git pre-commit hook](https://github.com/dotenvx/dotenvx#pre-commit) to prevent this from ever happening again.
657659

658660
```
659-
brew install dotenvx/brew/dotenvx
661+
npm i -g @dotenvx/dotenvx
660662
dotenvx precommit --install
661663
```
662664

0 commit comments

Comments
 (0)