Skip to content

wenderjean/checkdotenv

Repository files navigation

checkdotenv

npm version Dependency Status Build Status

It's a project intended to verify if all environment variables previously wrote in the recipe are already set in process.env.

Dependencies

Node 6.4.0+

Install

npm install checkdotenv --save

Usage

First, define a file .env.example in your project root and then put the line below in top the entry file of your application.

require('checkdotenv').check();

Options

By default checkdotenv will looking for a recipe called .env.example but check method may receive a parameter to change that filename.

require('checkdotenv').check('yourfilename');

Test

npm run test