Log sketchbook watch.

Signed-off-by: Akos Kitta <kittaakos@typefox.io>
This commit is contained in:
Akos Kitta 2021-02-01 12:19:59 +01:00 committed by Akos Kitta
parent 79bf0a123f
commit 770e0b592a

View File

@ -197,9 +197,10 @@ export class SketchesServiceImpl implements SketchesService {
}); });
// TODO: no `await` for some reason this blocks the workspace root initialization on Windows inside a bundled electron app. // TODO: no `await` for some reason this blocks the workspace root initialization on Windows inside a bundled electron app.
console.log(`Starting to watch sketchbook at '${sketchbookPath}'.`);
watcher.start() watcher.start()
.then(() => console.log(`Initialized NSFW in sketchbook: '${sketchbookPath}. Watching for sketch changes.`)) .then(() => console.log(`Initialized watcher in sketchbook: '${sketchbookPath}. Watching for sketch changes.`))
.catch(err => console.error(`Failed to initialize NSFW in sketchbook '${sketchbookPath}'. Cannot track sketch changes.`, err)); .catch(err => console.error(`Failed to initialize watcher in sketchbook '${sketchbookPath}'. Cannot track sketch changes.`, err));
deferred.resolve(sketches); deferred.resolve(sketches);
this.sketchbooks.set(sketchbookPath, sketches); this.sketchbooks.set(sketchbookPath, sketches);