Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/zkochan/subenv
Returns all the environment variables that are prefixed with the specified value
https://github.com/zkochan/subenv
Last synced: 3 months ago
JSON representation
Returns all the environment variables that are prefixed with the specified value
- Host: GitHub
- URL: https://github.com/zkochan/subenv
- Owner: zkochan
- License: mit
- Created: 2017-04-16T19:45:35.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2017-08-06T20:10:57.000Z (over 7 years ago)
- Last Synced: 2024-10-05T09:41:41.225Z (3 months ago)
- Language: JavaScript
- Homepage:
- Size: 22.5 KB
- Stars: 5
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# subenv
> Returns all the environment variables that are prefixed with the specified value
[![npm version](https://img.shields.io/npm/v/subenv.svg)](https://www.npmjs.com/package/subenv) [![Build Status](https://img.shields.io/travis/zkochan/subenv/master.svg)](https://travis-ci.org/zkochan/subenv)
## Installation
```sh
npm i -S subenv
```## Usage
```js
'use strict'
const subenv = require('subenv')process.env.capitals_USA = 'Washington'
process.env.capitals_hungary = 'Budapest'console.log(subenv('capitals'))
//> { usa: 'Washington', hungary: 'Budapest' }
```## License
[MIT](./LICENSE) © [Zoltan Kochan](https://www.kochan.io)