Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

crypto-settings

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

crypto-settings

  • 0.0.3
  • latest
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

A module to save settings data, it has a fair bit of configurability, but it's intended usage is very simple:

Installation

npm install crypto-settings

Basic Usage

var settings = require("crypto-settings")(/* optional options object goes here */);

//make use of any settings required.

Command line to start.

app.js -pass myPasswordWithNoSpaces -print -edit

If used in this fassion, a password can be specified on the command line (providing it has no spaces) in the format -pass

Adding the flag -print will cause the settings object to be printed to the console on startup.

Adding the flag -edit will give a command line interface to allow editing of settings. The command line interface has access to a "settings" object. This will be automatically saved when the command line exits.

The settings object returned always has two methods (which should be treated as reserved words).

save()

syncronously writes the data back to the file.

useConsole(callback)

Does the same as if the user had used "-edit" flag, then triggers the callback once the user has finished editing settings.

Async mode

Documentation needed.

Using alternative stores

Documentation needed.

FAQs

Package last updated on 30 Mar 2012

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc