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

monocle

Package Overview
Dependencies
Maintainers
1
Versions
17
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

monocle - npm Package Compare versions

Comparing version 1.1.50 to 1.1.51

6

monocle.js
var path = require('path');
var fs = require('fs');
var readdirp = require('readdirp');
var is_windows = process.platform === 'win32';
var use_fs_watch = process.platform === 'win32' || process.env.USE_FS_WATCH;

@@ -53,3 +53,3 @@ module.exports = function() {

function unwatchAll() {
if (is_windows) {
if (use_fs_watch) {
Object.keys(watched_files).forEach(function(key) {

@@ -104,3 +104,3 @@ watched_files[key].close();

if (!watched_files[file.fullPath]) {
if (is_windows) {
if (use_fs_watch) {
(function() {

@@ -107,0 +107,0 @@ watched_files[file.fullPath] = fs.watch(file.fullPath, function() {

{
"name": "monocle",
"version": "1.1.50",
"version": "1.1.51",
"description": "a tool for watching directories for file changes",

@@ -16,3 +16,3 @@ "main": "monocle.js",

"scripts": {
"test": "mocha test -R spec -t 5000"
"test": "mocha test -R spec -t 2000"
},

@@ -19,0 +19,0 @@ "repository": {

@@ -70,2 +70,6 @@ [![Build Status](https://travis-ci.org/samccone/monocle.png?branch=master)](https://travis-ci.org/samccone/monocle)

### Force to use fs.watch
You can use the USE_FS_WATCH env variable set to true, to force this behavior regardless of platform.
## Why not just use fs.watch ?

@@ -72,0 +76,0 @@

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