Security News
tea.xyz Spam Plagues npm and RubyGems Package Registries
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
watch-glob
Advanced tools
Readme
Watch files and directories with glob patterns
npm install watch-glob
watchGlob(patterns, [options], addedCallback, [removedCallback] ])
patterns
- a glob pattern or array of glob patterns to watchoptions
- the base folder in which to search for the patterns (equivalent to options.cwd
) an options object to pass to glob()
, plus the following:
callbackArg
- how the file should be represented on the callback
absolute
- absolute pathrelative
- path relative to `options.cwd´vinyl
- a vinyl-fs object (experimental)object
(default) - { base, path, relative }delay
- (default: 2000
) sometimes Gaze does not seem to correctly watch folders which have not been created yet. Therefore, a 2000ms delay is usedupdateCallback
- function to be called when a file is changed, created, or "created" through a renameremoveCallback
- function to be called after a file is is deleted or "deleted" through a renamevar watchGlob = require('watch-glob'),
coffee = require('coffee-files');
watchGlob(['tmp/**/*', 'lib/**/*'], { callbackArg: 'relative' }, function(filePath) {
// Perform livereload
});
watchGlob('coffee/**/*.coffee', { cwd: 'src' }, function(filepath) {
coffee.file(filepath.path, 'build/' + filepath.relative);
});
FAQs
Watch glob patterns
The npm package watch-glob receives a total of 293 weekly downloads. As such, watch-glob popularity was classified as not popular.
We found that watch-glob demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
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.
Security News
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
Security News
As cyber threats become more autonomous, AI-powered defenses are crucial for businesses to stay ahead of attackers who can exploit software vulnerabilities at scale.
Security News
UnitedHealth Group disclosed that the ransomware attack on Change Healthcare compromised protected health information for millions in the U.S., with estimated costs to the company expected to reach $1 billion.