MCPcopy
hub / github.com/mozilla/web-ext / proxyFileChanges

Function proxyFileChanges

src/watcher.js:77–90  ·  view source on GitHub ↗
({
  artifactsDir,
  onChange,
  filePath,
  shouldWatchFile,
})

Source from the content-addressed store, hash-verified

75// proxyFileChanges types and implementation.
76
77export function proxyFileChanges({
78 artifactsDir,
79 onChange,
80 filePath,
81 shouldWatchFile,
82}) {
83 if (filePath.indexOf(artifactsDir) === 0 || !shouldWatchFile(filePath)) {
84 log.debug(`Ignoring change to: ${filePath}`);
85 } else {
86 log.debug(`Changed: ${filePath}`);
87 log.debug(`Last change detection: ${new Date().toTimeString()}`);
88 onChange();
89 }
90}

Callers 2

test.watcher.jsFile · 0.90
onSourceChangeFunction · 0.85

Calls 1

shouldWatchFileFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…