Skip to content
/ beenvo Public

Beenvo let you loads environment variables from files (support many files extensions) for Node.js projects into `process.env` 🐝.

License

Notifications You must be signed in to change notification settings

beenvo/beenvo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

52 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Beenvo



Build Status Coverage Status NPM version Code Size License


Beenvo let you loads environment variables from files (support many files extensions) for Node.js projects into `process.env` 🐝.

Features

  • πŸ¦„ Β  Inspired from dotenv.

  • πŸš€ Β  Isomorphic to the moon.

  • πŸ”₯ Β  Blaze and lightweight.

  • πŸ±β€πŸ‰ Β  Support many files extensions (not only .env*);

    • βœ… Β  Toml (*.toml) support.
    • βœ… Β  Yaml (*.yml and *.yaml) support.
    • βœ… Β  Properties (*.ini and *.properties) support.
    • βœ… Β  Xml (*.xml) support.
    • βœ… Β  Json (*.json) support.
    • βœ… Β  dotEnv (.env*) support.
  • 🧼 Support clean up variables loaded inside process.env.

  • πŸ“Ÿ Β  Support preload (with cli). [🚧 - welcome to any kind of help πŸ‘‹πŸ»]

  • πŸ±β€πŸ‘€ Β  Strong competitor to the rest dotEnv modules.

  • 🐒 Β  Node.js support.

  • πŸ¦• Β  Deno support. [🚧 - welcome to any kind of help πŸ‘‹πŸ»]

  • πŸŽ‰ Β  TypeScript support.

Notes: Require Node 12+.

Installation

# npm
$ npm install beenvo
# yarn
$ yarn add beenvo

Usage

This is a practical example of how to use.

# create your variables file with name `env.yaml`.
SOME_NUMBER: 1000
SOME_STRING: "don't do that"
// const beenvo = require("beenvo");
import beenvo from "beenvo";

const options = { path: "env.yaml" };

beenvo(options);

// process.env.SOME_NUMBER // 1000
// process.env.SOME_STRING // "don't do that"

if you want more example you can check the test folder or open an issue πŸ˜‰.

OPTIONS

You can pass options object to beenvo;

  • options.path β€” (String) represent path to the file which contains your variables (default to '.env').
  • options.cleanup β€” (Boolean) to remove all loaded variables (default to false).

Support

If you have any problem or suggestion please open an issue.

License


MIT Β© Imed Jaberi

About

Beenvo let you loads environment variables from files (support many files extensions) for Node.js projects into `process.env` 🐝.

Resources

License

Stars

Watchers

Forks

Packages

No packages published