@wrongstack/plugins 0.236.0 → 0.250.0

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.
@@ -99,26 +99,15 @@ var plugin = {
99
99
  if (autoIndex && isIndexableFile(fullPath)) {
100
100
  debounceEvent(`index:${fullPath}`, async () => {
101
101
  try {
102
- const { runIndexer } = await import('@wrongstack/tools/codebase-index/index.js');
102
+ const { enqueueReindex } = await import('@wrongstack/tools/codebase-index/index.js');
103
103
  const root = indexProjectRoot || dirPath;
104
- const fakeAppend = async () => {
105
- };
106
- const fakeClose = async () => {
107
- };
108
- const fakeRecordFileChange = () => {
109
- };
110
- const ctx = {
104
+ enqueueReindex({
111
105
  projectRoot: root,
112
- cwd: root,
113
- messages: [],
114
- todos: [],
115
- readFiles: /* @__PURE__ */ new Set(),
116
- fileMtimes: /* @__PURE__ */ new Map(),
117
- session: { id: "fw", append: fakeAppend, close: fakeClose, recordFileChange: fakeRecordFileChange }
118
- };
119
- await runIndexer(ctx, { projectRoot: root, files: [fullPath] });
106
+ files: [fullPath],
107
+ onError: (err) => api.log.warn(`file-watcher: auto-index failed for ${fullPath}: ${err}`)
108
+ });
120
109
  api.metrics.counter("index_file", 1);
121
- api.log.debug(`file-watcher: auto-index triggered for ${fullPath}`);
110
+ api.log.debug(`file-watcher: auto-index scheduled for ${fullPath}`);
122
111
  } catch (err) {
123
112
  api.log.warn(`file-watcher: auto-index failed for ${fullPath}: ${err}`);
124
113
  }
@@ -10,7 +10,8 @@ function runGit(args, cwd) {
10
10
  cwd,
11
11
  stdio: ["pipe", "pipe", "pipe"],
12
12
  timeout: 3e4,
13
- maxBuffer: 10 * 1024 * 1024
13
+ maxBuffer: 10 * 1024 * 1024,
14
+ windowsHide: true
14
15
  }).trim();
15
16
  } catch (err) {
16
17
  const e = err;
package/dist/index.js CHANGED
@@ -251,7 +251,8 @@ function runGit(args, cwd) {
251
251
  cwd,
252
252
  stdio: ["pipe", "pipe", "pipe"],
253
253
  timeout: 3e4,
254
- maxBuffer: 10 * 1024 * 1024
254
+ maxBuffer: 10 * 1024 * 1024,
255
+ windowsHide: true
255
256
  }).trim();
256
257
  } catch (err) {
257
258
  const e = err;
@@ -669,7 +670,7 @@ var API_VERSION2 = "^0.1.10";
669
670
  function runShellCheck(files, severity, cwd) {
670
671
  if (!existsSync("shellcheck")) {
671
672
  try {
672
- execSync("shellcheck --version", { encoding: "utf-8", stdio: "ignore" });
673
+ execSync("shellcheck --version", { encoding: "utf-8", stdio: "ignore", windowsHide: true });
673
674
  } catch {
674
675
  throw new Error("shellcheck is not installed. Install via: apt install shellcheck / brew install shellcheck");
675
676
  }
@@ -693,7 +694,8 @@ function runShellCheck(files, severity, cwd) {
693
694
  encoding: "utf-8",
694
695
  cwd,
695
696
  stdio: ["pipe", "pipe", "pipe"],
696
- timeout: 6e4
697
+ timeout: 6e4,
698
+ windowsHide: true
697
699
  });
698
700
  } catch (err) {
699
701
  const e = err;
@@ -1202,26 +1204,15 @@ var plugin5 = {
1202
1204
  if (autoIndex && isIndexableFile(fullPath)) {
1203
1205
  debounceEvent(`index:${fullPath}`, async () => {
1204
1206
  try {
1205
- const { runIndexer } = await import('@wrongstack/tools/codebase-index/index.js');
1207
+ const { enqueueReindex } = await import('@wrongstack/tools/codebase-index/index.js');
1206
1208
  const root = indexProjectRoot || dirPath;
1207
- const fakeAppend = async () => {
1208
- };
1209
- const fakeClose = async () => {
1210
- };
1211
- const fakeRecordFileChange = () => {
1212
- };
1213
- const ctx = {
1209
+ enqueueReindex({
1214
1210
  projectRoot: root,
1215
- cwd: root,
1216
- messages: [],
1217
- todos: [],
1218
- readFiles: /* @__PURE__ */ new Set(),
1219
- fileMtimes: /* @__PURE__ */ new Map(),
1220
- session: { id: "fw", append: fakeAppend, close: fakeClose, recordFileChange: fakeRecordFileChange }
1221
- };
1222
- await runIndexer(ctx, { projectRoot: root, files: [fullPath] });
1211
+ files: [fullPath],
1212
+ onError: (err) => api.log.warn(`file-watcher: auto-index failed for ${fullPath}: ${err}`)
1213
+ });
1223
1214
  api.metrics.counter("index_file", 1);
1224
- api.log.debug(`file-watcher: auto-index triggered for ${fullPath}`);
1215
+ api.log.debug(`file-watcher: auto-index scheduled for ${fullPath}`);
1225
1216
  } catch (err) {
1226
1217
  api.log.warn(`file-watcher: auto-index failed for ${fullPath}: ${err}`);
1227
1218
  }
@@ -2430,7 +2421,8 @@ function runGit2(args, cwd) {
2430
2421
  encoding: "utf-8",
2431
2422
  cwd,
2432
2423
  stdio: ["pipe", "pipe", "pipe"],
2433
- timeout: 3e4
2424
+ timeout: 3e4,
2425
+ windowsHide: true
2434
2426
  }).trim();
2435
2427
  } catch (err) {
2436
2428
  const e = err;
@@ -10,7 +10,8 @@ function runGit(args, cwd) {
10
10
  encoding: "utf-8",
11
11
  cwd,
12
12
  stdio: ["pipe", "pipe", "pipe"],
13
- timeout: 3e4
13
+ timeout: 3e4,
14
+ windowsHide: true
14
15
  }).trim();
15
16
  } catch (err) {
16
17
  const e = err;
@@ -7,7 +7,7 @@ var API_VERSION = "^0.1.10";
7
7
  function runShellCheck(files, severity, cwd) {
8
8
  if (!existsSync("shellcheck")) {
9
9
  try {
10
- execSync("shellcheck --version", { encoding: "utf-8", stdio: "ignore" });
10
+ execSync("shellcheck --version", { encoding: "utf-8", stdio: "ignore", windowsHide: true });
11
11
  } catch {
12
12
  throw new Error("shellcheck is not installed. Install via: apt install shellcheck / brew install shellcheck");
13
13
  }
@@ -31,7 +31,8 @@ function runShellCheck(files, severity, cwd) {
31
31
  encoding: "utf-8",
32
32
  cwd,
33
33
  stdio: ["pipe", "pipe", "pipe"],
34
- timeout: 6e4
34
+ timeout: 6e4,
35
+ windowsHide: true
35
36
  });
36
37
  } catch (err) {
37
38
  const e = err;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wrongstack/plugins",
3
- "version": "0.236.0",
3
+ "version": "0.250.0",
4
4
  "description": "Official WrongStack plugin collection — auto-doc, git-autocommit, shell-check, cost-tracker, file-watcher, web-search, json-path, cron, template-engine, semver-bump",
5
5
  "license": "MIT",
6
6
  "author": "ECOSTACK TECHNOLOGY OÜ",
@@ -63,7 +63,7 @@
63
63
  "vitest": "^4.1.8"
64
64
  },
65
65
  "dependencies": {
66
- "@wrongstack/core": "0.236.0"
66
+ "@wrongstack/core": "0.250.0"
67
67
  },
68
68
  "scripts": {
69
69
  "build": "tsup",