Socket
Book a DemoInstallSign in
Socket

common-shell-scripts

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

common-shell-scripts

A set of small NodeJS scripts that might come in useful.

latest
Source
npmnpm
Version
0.0.2
Version published
Maintainers
1
Created
Source

A set of shell scripts that I use quite a lot across different projects, for the times where Grunt / Gulp / etc is just too much.

Usage

npm install --save-dev common-shell-scripts

Then you can call a script, for example the watch script, like so:

./node_modules/common-shell-scripts/watch {arg1} {arg2}

The typical usage is to put these into a Makefile, or similar. The Makefile of Totesy shows this in action.

Commands

watch

Watch a directory or file for changes and run something when changes are detected.

./watch directory/to/watch command_to_run

replace_secrets

Useful for placing secret information (API Keys, etc) in files but not in version control.

Given a JSON file secrets.json like so:

{ "my_secret_key": "1234ABC" }

And app.js like this:

var myApiKey = '!my_secret_key!';

Running:

./replace_secrets secrets.json app.js

Will result in app.js reading like so:

var myApiKey = '1234ABC';

Keywords

shell

FAQs

Package last updated on 14 May 2014

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

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.