Skip to content

Commit

Permalink
directories ignored by watcher should be relative to the watch direct…
Browse files Browse the repository at this point in the history
…ory (#9703)

Co-authored-by: ngrujic <ngrujic@atlassian.com>
  • Loading branch information
Nikola-3 and ngrujic committed May 8, 2024
1 parent a7b7e8a commit eb54820
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/core/core/src/RequestTracker.js
Expand Up @@ -1483,12 +1483,12 @@ export default class RequestTracker {
export function getWatcherOptions({
watchIgnore = [],
cacheDir,
projectRoot,
watchDir,
watchBackend,
}: ParcelOptions): WatcherOptions {
const vcsDirs = ['.git', '.hg'];
const uniqueDirs = [...new Set([...watchIgnore, ...vcsDirs, cacheDir])];
const ignore = uniqueDirs.map(dir => path.resolve(projectRoot, dir));
const ignore = uniqueDirs.map(dir => path.resolve(watchDir, dir));

return {ignore, backend: watchBackend};
}
Expand Down

0 comments on commit eb54820

Please sign in to comment.