This package has been deprecated

Author message:

NO LONGER MAINTAINED

the-env

3.0.6 • Public • Published

the-env

Build Status npm Version JS Standard

Env resolver for the-framework

Installation

$ npm install the-env --save

Usage

Create a directory with name "env" and put env setting files like "database.json" there.

env/database.json

{
  "default": {
    "HOST": "localhost",
    "SHCEMA": "myapp",
    "USER": "myapp-db-user",
    "PASSWORD": "password-of-#{USER}"
  },
  "production": {
    "HOST": "http://myapp-db.com",
    "USER": "myapp-db-user-production",
    "PASSWORD": "a;skdjfasdwer"
  },
  "development": {
    "USER": "myapp-db-user-dev",
    "PASSWORD": "myapp-db-user-dev"
  }
}

env/index.js

'use strict'

const theEnv = require('the-env')

const env = theEnv({
  database: require('./database')
}).forEnv()

module.exports = env

API Guide

License

This software is released under the MIT License.

Readme

Keywords

Package Sidebar

Install

npm i the-env

Weekly Downloads

11

Version

3.0.6

License

MIT

Unpacked Size

40 kB

Total Files

35

Last publish

Collaborators

  • okunishinishi