@tekyzinc/gsd-t 2.31.10 → 2.31.12
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.
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tekyzinc/gsd-t",
|
|
3
|
-
"version": "2.31.
|
|
3
|
+
"version": "2.31.12",
|
|
4
4
|
"description": "GSD-T: Contract-Driven Development for Claude Code — 46 slash commands with backlog management, impact analysis, test sync, milestone archival, and PRD generation",
|
|
5
5
|
"author": "Tekyz, Inc.",
|
|
6
6
|
"license": "MIT",
|
|
@@ -6,20 +6,27 @@
|
|
|
6
6
|
* Outputs to stdout: injected as system context before Claude processes the prompt.
|
|
7
7
|
*
|
|
8
8
|
* Logic:
|
|
9
|
+
* - Not a GSD-T project (no .gsd-t/progress.md in cwd) → exit silently
|
|
9
10
|
* - Prompt starts with "/" → exit silently (user typed a command, pass through)
|
|
10
11
|
* - Prompt is plain text → emit [GSD-T AUTO-ROUTE] signal so Claude routes via /gsd
|
|
11
12
|
*/
|
|
12
13
|
|
|
14
|
+
const fs = require("fs");
|
|
15
|
+
const path = require("path");
|
|
16
|
+
|
|
13
17
|
let input = "";
|
|
14
18
|
process.stdin.setEncoding("utf8");
|
|
15
19
|
process.stdin.on("data", (chunk) => { input += chunk; });
|
|
16
20
|
process.stdin.on("end", () => {
|
|
17
21
|
try {
|
|
18
22
|
const data = JSON.parse(input);
|
|
23
|
+
// Guard: only activate in GSD-T projects
|
|
24
|
+
const cwd = typeof data.cwd === "string" ? data.cwd : process.cwd();
|
|
25
|
+
if (!fs.existsSync(path.join(cwd, ".gsd-t", "progress.md"))) process.exit(0);
|
|
19
26
|
const prompt = (typeof data.prompt === "string" ? data.prompt : "").trimStart();
|
|
20
27
|
if (prompt.startsWith("/")) process.exit(0); // slash command — pass through
|
|
21
28
|
if (!prompt) process.exit(0); // empty prompt — pass through
|
|
22
|
-
// Plain text prompt — inject routing signal
|
|
29
|
+
// Plain text prompt in a GSD-T project — inject routing signal
|
|
23
30
|
process.stdout.write(
|
|
24
31
|
"[GSD-T AUTO-ROUTE] The user typed a plain text message (no leading /). " +
|
|
25
32
|
"Route it automatically through the /gsd smart router — execute the /user:gsd " +
|
|
@@ -191,7 +191,7 @@ On session start, a version check hook auto-updates GSD-T and outputs a status m
|
|
|
191
191
|
|
|
192
192
|
Only execute GSD-T workflow behavior when a `/gsd-t-*` command is invoked or when actively mid-phase (resumed via `/gsd-t-resume`). **Plain text messages — especially questions — should be answered conversationally.** Do not launch into workflow execution, file reading, or phase advancement from a question or comment. If the user wants work done, they will invoke a command.
|
|
193
193
|
|
|
194
|
-
**Exception — Auto-Route signal**: When `[GSD-T AUTO-ROUTE]` appears in your context (injected by the UserPromptSubmit hook), the user's plain text message should be treated as a `/user:gsd {message}` invocation. Execute the `/gsd` smart router with the user's full message as the argument instead of replying conversationally.
|
|
194
|
+
**Exception — Auto-Route signal**: When `[GSD-T AUTO-ROUTE]` appears in your context (injected by the UserPromptSubmit hook), the user's plain text message should be treated as a `/user:gsd {message}` invocation. Execute the `/gsd` smart router with the user's full message as the argument instead of replying conversationally. The hook only fires in GSD-T projects (directories containing `.gsd-t/progress.md`) — it silently passes through in all other directories.
|
|
195
195
|
|
|
196
196
|
## Auto-Init Guard
|
|
197
197
|
|
|
@@ -206,7 +206,7 @@ If any are missing:
|
|
|
206
206
|
1. Run `gsd-t-init` automatically (it skips files that already exist)
|
|
207
207
|
2. Then continue with the originally requested command
|
|
208
208
|
|
|
209
|
-
**Exempt commands** (do not trigger auto-init): `gsd-t-init`, `gsd-t-init-scan-setup`, `gsd-t-help`, `gsd-t-version-update`, `gsd-t-version-update-all
|
|
209
|
+
**Exempt commands** (do not trigger auto-init): `gsd-t-init`, `gsd-t-init-scan-setup`, `gsd-t-help`, `gsd-t-version-update`, `gsd-t-version-update-all`.
|
|
210
210
|
|
|
211
211
|
## Playwright Readiness Guard
|
|
212
212
|
|