Get unlimited public & private packages + package-based permissions with npm Pro.Get started »

This package has been deprecated

Author message:

The package is no longer maintained. Use the npm package dotenv instead.

dotenv-node

0.0.2 • Public • Published

DotEnv for Node.js

Build Status

DotEnv loads environment variables from .env into your ENV.

Installation

As early as possible in your application require dotenv and load the .env variables.

DotEnv = require('dotenv-node');
new DotEnv();

Usage

Add your application configuration to a .env file in the root of your project:

S3_BUCKET=YOURS3BUCKET
SECRET_KEY=YOURSECRETKEYGOESHERE

When your application loads, these variables will be available via process.env:

process.env.S3_BUCKET;
process.env.SECRET_KEY;

Inspiration

Contributing

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Added some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request

Running tests

npm install
npm test

Install

npm i dotenv-node

DownloadsWeekly Downloads

5

Version

0.0.2

License

BSD

Last publish

Collaborators

  • avatar
  • avatar