Function
watch
(
backend: Option.Option<Context.Tag.Service<FileSystem.WatchBackend>>,
path: string,
options?: FileSystem.WatchOptions
)
Source from the content-addressed store, hash-verified
| 579 | ) |
| 580 | |
| 581 | const watch = ( |
| 582 | backend: Option.Option<Context.Tag.Service<FileSystem.WatchBackend>>, |
| 583 | path: string, |
| 584 | options?: FileSystem.WatchOptions |
| 585 | ) => |
| 586 | stat(path).pipe( |
| 587 | Effect.map((stat) => |
| 588 | backend.pipe( |
| 589 | Option.flatMap((_) => _.register(path, stat, options)), |
| 590 | Option.getOrElse(() => watchNode(path, options)) |
| 591 | ) |
| 592 | ), |
| 593 | Stream.unwrap |
| 594 | ) |
| 595 | |
| 596 | // == writeFile |
| 597 | |
Callers
nothing calls this directly
Tested by
no test coverage detected
Used in the wild real call sites across dependent graphs
searching dependent graphs…