vovk-cli 0.0.1-draft.2 → 0.0.1-draft.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -137,6 +137,7 @@ export class VovkCLIWatcher {
137
137
  this.#watchModules();
138
138
  this.#watchSegments();
139
139
  }, 1000);
140
+ let ready = false;
140
141
  chokidar
141
142
  .watch(['vovk.config.{js,mjs,cjs}', '.config/vovk.config.{js,mjs,cjs}'], {
142
143
  persistent: true,
@@ -148,7 +149,11 @@ export class VovkCLIWatcher {
148
149
  .on('change', () => void handle())
149
150
  .on('unlink', () => void handle())
150
151
  .on('ready', () => {
152
+ if (ready)
153
+ return;
154
+ // for some reason this watcher triggers ready event twice
151
155
  log.debug('Config files watcher is ready');
156
+ ready = true;
152
157
  })
153
158
  .on('error', (error) => {
154
159
  log.error(`Error watching config files: ${error.message}`);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vovk-cli",
3
- "version": "0.0.1-draft.2",
3
+ "version": "0.0.1-draft.4",
4
4
  "bin": {
5
5
  "vovk": "./dist/index.mjs"
6
6
  },