Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/ngryman/letenv
CLI environment variables loader.
https://github.com/ngryman/letenv
Last synced: about 2 months ago
JSON representation
CLI environment variables loader.
- Host: GitHub
- URL: https://github.com/ngryman/letenv
- Owner: ngryman
- License: mit
- Created: 2016-02-24T00:12:11.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2018-06-26T07:45:23.000Z (about 6 years ago)
- Last Synced: 2024-07-26T13:38:27.683Z (about 2 months ago)
- Language: JavaScript
- Homepage:
- Size: 78.1 KB
- Stars: 1
- Watchers: 3
- Forks: 0
- Open Issues: 6
-
Metadata Files:
- Readme: readme.md
- License: license
Awesome Lists containing this project
README
# letenv [![travis][travis-image]][travis-url] [![codecov][codecov-image]][codecov-url]
[travis-image]: https://img.shields.io/travis/ngryman/letenv.svg
[travis-url]: https://travis-ci.org/ngryman/letenv
[codecov-image]: https://img.shields.io/codecov/c/github/ngryman/letenv.svg
[codecov-url]: https://codecov.io/github/ngryman/letenv> CLI environment variables loader.
*letenv* does what it advertises. The only difference between other `.env` loaders is that it can be used via `cli` and wrap a process passed as argument. This is really useful when you want to load environement variables along your test runner for example.
## Install
```sh
# cli
npm install -g letenv# api
npm install --save letenv
```## Usage
### CLI
```sh
letenv [command] [arguments]# i.e
letenv nyc ava
```### API
```javascript
require('letenv')()// => process.env is now populated
```## `.env` file
A classic key-value pair file:
```ini
NODE_ENV=test
WASABI=good
```## License
MIT © [Nicolas Gryman](http://ngryman.sh)