# envisor

> Universal library for managing your environment variables

Latest version **0.1.0** (published 2015-04-05) · 0 weekly downloads

## Install

```sh
npm install envisor
pnpm add envisor
yarn add envisor
bun add envisor
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.1.0 |
| Published | 2015-04-05 |
| First published | 2015-04-05 |
| Weekly downloads | 0 |
| TypeScript types | none |
| Module format | CommonJS |
| Node | >=0.10.28 |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Abashkin Alexander |
| Maintainers | monolithed |
| Keywords | env, config, export, environment, variables, management |

## Links

- npm: https://www.npmjs.com/package/envisor
- Repository: https://github.com/monolithed/envisor
- Homepage: https://github.com/monolithed/envisor.git
- Issues: https://github.com/monolithed/envisor/issues
- npm.io page: https://npm.io/package/envisor

## Alternatives

- [replicas-cli](https://npm.io/package/replicas-cli.md) — 3.0K weekly downloads
- [env-contract](https://npm.io/package/env-contract.md) — 133 weekly downloads
- [@openveo/api](https://npm.io/package/@openveo/api.md) — 61 weekly downloads
- [@ryniaubenpm2/cumque-error-reiciendis](https://npm.io/package/@ryniaubenpm2/cumque-error-reiciendis.md) — 54 weekly downloads
- [ts-global-type-extra](https://npm.io/package/ts-global-type-extra.md) — 11 weekly downloads

## Recent versions

- 0.1.0 (latest) — 2015-04-05
- 0.0.1 — 2015-04-05

## README

# envisor

[![npm version badge](https://img.shields.io/npm/v/envisor.svg)](https://www.npmjs.org/package/envisor)
[![Build Status](https://travis-ci.org/monolithed/envisor.png)](https://travis-ci.org/monolithed/envisor)
[![License](https://img.shields.io/badge/license-MIT-brightgreen.svg)](LICENSE.txt)


> Universal library for managing your environment variables


*Environment variables are a set of dynamic named values that can affect the way running processes will behave on a computer. <br />
They are part of the environment in which a process runs*


## License
	MIT


## Installation:

```shell
npm install envisor --save-dev
```


## Usage

*For example you could use the following code:*

```js
var env = require('envisor');

env.set('foo', 1);
env.get('foo'); // 1

```

### API

#### .set

*Sets/retrieves an environment variable*

*Primitive values*

```js
var env = require('envisor');

env.set('foo', 1);
env.get('foo'); // 1
```

*Object values*

```js
var env = require('envisor');

env.set('foo', { bar: 1});
env.get('foo).bar; // 1
```

*Object key/values*

```js
var env = require('envisor');

env.set({ foo: 1 });
env.get('foo'); // 1
```


#### .has

*Checks an environment variable*

```js
var env = require('envisor');

env.set('foo', 1);
env.has('foo'); // true
```


#### .use

*Use you personal namespace*

```js
var env = require('envisor');

env.use('foo');
env.set('bar', 1);
env.get('foo'); // 1
process.env.foo_bar; // 1
```


#### .remove

*Removes an environment variable*

```js
var env = require('envisor');

env.set('foo', 1);
env.remove('foo');
env.get('foo'); // ''
```

#### .all

*Returns all environment variables*

```js
var env = require('envisor');

env.all(); // process.env
```


### Tests

```
npm test
```


### Links
[Environment variables](http://en.wikipedia.org/wiki/Environment_variable) <br />
[process.env](https://nodejs.org/api/process.html#process_process_env)


Task submitted by [Alexander Abashkin](https://github.com/monolithed)

---
_Source: https://npm.io/package/envisor · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
