Skip to content

NazmusSayad/cli-node-env

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

cli-node-env

Simple usages of NODE_ENV

npm package

Features

  • No configuration
  • Lightweight

Installation

  • with npm
npm i cli-node-env
  • with yarn
yarn add cli-node-env
  • with pnpm
pnpm add cli-node-env

Usage:

/* index.js */

// Use this package at the top of your entry file

// Esmodules
import 'cli-node-env'
// CommonJS modules
require('cli-node-env')

console.log(process.env.NODE_ENV)

// ...
node index.js --NODE_ENV=production
node index.js --NODE_ENV=development
node index.js --NODE_ENV=whatever



Made by Nazmus Sayad with ❤️.