Socket
Socket
Sign inDemoInstall

senv

Package Overview
Dependencies
8
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.1.1 to 0.1.2

tests/index.test.js

2

index.js

@@ -102,2 +102,4 @@ const crypto = require('crypto'),

decryptEnvFile,
encryptString,
decryptString,
}
{
"name": "senv",
"version": "0.1.1",
"version": "0.1.2",
"description": "A simple CLI tool for encrypting and decrypting .env files",

@@ -11,2 +11,6 @@ "main": "index.js",

"bin": "./bin/senv",
"scripts": {
"test": "jest .",
"coverage": "jest --coverage ."
},
"dependencies": {

@@ -26,3 +30,6 @@ "commander": "^2.18.0",

"secure environment variable"
]
],
"devDependencies": {
"jest": "^23.5.0"
}
}

35

README.md

@@ -5,15 +5,31 @@ # 🔐 senv

## Basic Usage
Installation:
## Features:
- 🔒 Encrypt and decrypt `.env` files so they can be securely tracked in Git
- 👀 .env file changes are apparent during code review
- 🔢 Supports multiple `.env` files for different environment configurations
- 🎮 Supports encryption and decryption via CLI tool
- 🚢 Easy to configure for use with a CI system
## Installation:
`$ yarn global add senv`
or
`$ npm install -g senv`
Encrypt a plain text .env file:
## Basic Usage
#### Encrypt a plain text .env file:
`$ senv encrypt .env -o .env.enc -p password`
Decrypt an encrypted .env file:
#### Decrypt an encrypted .env file:
`$ senv decrypt .env.enc -o .env -p password`
## Advanced Usage

@@ -31,11 +47,6 @@

- Add the following line to your CI script:
`senv decrypt .env.enc -o .env -p $SENV_PASSWORD`
## Features:
- 🔒 Encrypt and decrypt .env files so they can be securely tracked in Git
- 👀 .env file changes are apparent during code review
- 🔢 Supports multiple .env files for different environment configurations
- 🎮 Supports encryption and decryption via CLI tool
- 🚢 Easy to configure for use with a CI system
`senv decrypt .env.enc -o .env -p $SENV_PASSWORD`
## Why?

@@ -45,3 +56,3 @@

This tool makes it easy to encrypt and decrypt any .env file so they can be securely tracked in Git.
This tool makes it easy to encrypt and decrypt any `.env` files so they can be securely tracked in Git.

@@ -48,0 +59,0 @@ There are several other great libraries that support encryption of environment variables ([encrypt-env](https://www.npmjs.com/package/encrypt-env), [secure-env](https://www.npmjs.com/package/secure-env), etc), but none fit our use case well (managing secrets in `.env` files with `react-native-config`) for one reason or another.

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc