mirror of
https://github.com/garrytan/gstack.git
synced 2026-10-31 22:14:25 +01:00
B5: shorter capture variable names (parity budget)
This commit is contained in:
1 parent
07c2e8cc88
commit
6de595e8d5
4 files changed
+8
-8
No files matched your search
@@ -106,8 +106,8 @@ Pick ONE keyword from the hypothesis. The keyword should be a noun: the failing
|
||||
Worked examples (investigate-specific): good keywords are `auth-cookie`, `session-expiry`, `redirect-loop`. Bad: `auth.ts:47`, `fix the auth bug`, `<hypothesis-keyword>`.
|
||||
|
||||
```bash
|
||||
{ _LERR=$(~/.claude/skills/gstack/bin/gstack-learnings-search --query "<your-keyword>" --limit 5 2>&1 >&3 3>&-); _LRC=$?; } 3>&1
|
||||
[ "$_LRC" = 0 ] || { _LERR=${_LERR%%$'\n'*}; echo "LEARNINGS: unavailable (${_LERR:-exit $_LRC})"; }
|
||||
{ _LE=$(~/.claude/skills/gstack/bin/gstack-learnings-search --query "<your-keyword>" --limit 5 2>&1 >&3 3>&-); _LR=$?; } 3>&1
|
||||
[ "$_LR" = 0 ] || { _LE=${_LE%%$'\n'*}; echo "LEARNINGS: unavailable (${_LE:-exit $_LR})"; }
|
||||
```
|
||||
|
||||
If any learnings come back, name which one applies to your investigation in one sentence. If none come back, continue without reference — the absence of a matching prior learning is itself useful information.
|
||||
|
||||
+2
-2
@@ -158,8 +158,8 @@ only letters, digits or hyphens (e.g., `checkout-button`, `payment`), never a pa
|
||||
quotes, whitespace or other punctuation; simplify to an alphanumeric stem if needed.
|
||||
|
||||
```bash
|
||||
{ _LERR=$(~/.claude/skills/gstack/bin/gstack-learnings-search --query "<your-keyword>" --limit 5 2>&1 >&3 3>&-); _LRC=$?; } 3>&1
|
||||
[ "$_LRC" = 0 ] || { _LERR=${_LERR%%$'\n'*}; echo "LEARNINGS: unavailable (${_LERR:-exit $_LRC})"; }
|
||||
{ _LE=$(~/.claude/skills/gstack/bin/gstack-learnings-search --query "<your-keyword>" --limit 5 2>&1 >&3 3>&-); _LR=$?; } 3>&1
|
||||
[ "$_LR" = 0 ] || { _LE=${_LE%%$'\n'*}; echo "LEARNINGS: unavailable (${_LE:-exit $_LR})"; }
|
||||
```
|
||||
|
||||
Name an applicable learning in one sentence, or continue if none applies.
|
||||
|
||||
@@ -26,8 +26,8 @@ const QUERY_SAFE_RE = /^[A-Za-z0-9 _-]+$/;
|
||||
* exit status kept, so a missing bun or a failed script prints why instead of
|
||||
* reading as "nothing recorded". Two lines: the capture, then the verdict.
|
||||
*/
|
||||
export const learningsCapture = (command: string) => `{ _LERR=$(${command} 2>&1 >&3 3>&-); _LRC=$?; } 3>&1`;
|
||||
export const LEARNINGS_VERDICT = `[ "$_LRC" = 0 ] || { _LERR=\${_LERR%%$'\\n'*}; echo "LEARNINGS: unavailable (\${_LERR:-exit $_LRC})"; }`;
|
||||
export const learningsCapture = (command: string) => `{ _LE=$(${command} 2>&1 >&3 3>&-); _LR=$?; } 3>&1`;
|
||||
export const LEARNINGS_VERDICT = `[ "$_LR" = 0 ] || { _LE=\${_LE%%$'\\n'*}; echo "LEARNINGS: unavailable (\${_LE:-exit $_LR})"; }`;
|
||||
|
||||
export function generateLearningsSearch(ctx: TemplateContext, args?: string[]): string {
|
||||
// Parse query= arg. Empty value falls through to no-query (principle of least surprise:
|
||||
|
||||
@@ -14,8 +14,8 @@ be alphanumeric or hyphen only; simplify other characters. For example, use
|
||||
`token-or-search`, not `feat: token-or search`.
|
||||
|
||||
```bash
|
||||
{ _LERR=$(~/.claude/skills/gstack/bin/gstack-learnings-search --query "<your-keyword>" --limit 5 2>&1 >&3 3>&-); _LRC=$?; } 3>&1
|
||||
[ "$_LRC" = 0 ] || { _LERR=${_LERR%%$'\n'*}; echo "LEARNINGS: unavailable (${_LERR:-exit $_LRC})"; }
|
||||
{ _LE=$(~/.claude/skills/gstack/bin/gstack-learnings-search --query "<your-keyword>" --limit 5 2>&1 >&3 3>&-); _LR=$?; } 3>&1
|
||||
[ "$_LR" = 0 ] || { _LE=${_LE%%$'\n'*}; echo "LEARNINGS: unavailable (${_LE:-exit $_LR})"; }
|
||||
```
|
||||
|
||||
Name an applicable learning and its effect on the version bump or CHANGELOG in
|
||||
|
||||
Reference in new issue
Block a user