https://github.com/pine/gulp-dotenv
:wrench: A .env file plugin for gulp: compiling .env to JSON
https://github.com/pine/gulp-dotenv
Last synced: 10 months ago
JSON representation
:wrench: A .env file plugin for gulp: compiling .env to JSON
- Host: GitHub
- URL: https://github.com/pine/gulp-dotenv
- Owner: pine
- License: mit
- Created: 2015-10-04T17:33:58.000Z (over 10 years ago)
- Default Branch: master
- Last Pushed: 2019-06-21T07:07:39.000Z (almost 7 years ago)
- Last Synced: 2025-05-09T05:03:01.773Z (11 months ago)
- Language: JavaScript
- Homepage:
- Size: 19.5 KB
- Stars: 3
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# gulp-dotenv
[](https://www.npmjs.com/package/gulp-dotenv)
[](https://travis-ci.org/pine/gulp-dotenv)
[](https://david-dm.org/pine/gulp-dotenv)
[](https://david-dm.org/pine/gulp-dotenv#info=devDependencies)
A .env file plugin for gulp: compiling .env to JSON
## Installation
```
$ npm install gulp-dotenv --save
```
## Usage
`.env` is a `\n` separated key-value configuration file like `KEY=VALUE`.
```js
var dotenv = require('gulp-dotenv');
var rename = require('gulp-rename');
gulp.task('dotenv', function () {
return gulp.src('.env')
.pipe(dotenv())
.pipe(rename('env.json'))
.pipe(gulp.dest('dist'));
});
```
## License
MIT © Pine Mizune