Socket
Socket
Sign inDemoInstall

ergol

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ergol - npm Package Compare versions

Comparing version 1.0.1 to 1.0.2

10

package.json

@@ -5,3 +5,3 @@ {

"description": "Meant to run on top of another script during development, reload the app after every change in the codebase",
"version": "1.0.1",
"version": "1.0.2",
"bin": {

@@ -11,6 +11,6 @@ "ergol": "./bin/reloader"

"dependencies": {
"chokidar": "^3.5.1",
"cli-color": "^2.0.0",
"eslint": "^7.25.0",
"yargs": "^17.0.1"
"chokidar": "^3.5.3",
"cli-color": "^2.0.1",
"eslint": "^8.7.0",
"yargs": "^17.3.1"
},

@@ -17,0 +17,0 @@ "engines": {

@@ -32,2 +32,4 @@ /*

let notEnoughWatcherError = false;
/**

@@ -48,3 +50,3 @@ * Process running under this one and that is reloaded when necessary

* and only then restarts it.
*
*
* @param {Object} config Configuration variables

@@ -73,2 +75,25 @@ * @param {string} script Path to the script that runs under this process and that is reloaded when necessary

process.on('unhandledRejection', async error => {
if (error.message.includes('ENOSPC')) {
if (notEnoughWatcherError) {
return;
}
notEnoughWatcherError = true;
console.error(error.message);
console.error(' You system does not have enough file watchers to run Ergol.');
console.error(' You need to increase this number:');
console.error(' - Linux: "sudo sysctl -w fs.inotify.max_user_watches=524288"');
console.error(' - OSX: "sudo sysctl -w kern.maxfiles=524288"');
console.error('\n Or you can just search "increase system file watcher <your os>"');
await stopProcess(config.killDelay);
process.exit(1);
}
else {
throw error;
}
});
startProcess(script, config.scriptArgs, config.nodeArgs);

@@ -79,3 +104,3 @@ }

* Starts the child process with the given args
*
*
* @param {string} script Path to the script that runs under this process and that is reloaded when necessary

@@ -118,3 +143,3 @@ * @param {Array<string>} scriptArgs Arguments to pass to the script (Default to [])

* Gracefully shuts the current process down or kills it after some delay
*
*
* @param {number} killDelay Max delay after which the process must be killed

@@ -121,0 +146,0 @@ */

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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