Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .claude-plugin/marketplace.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"$schema": "https://anthropic.com/claude-code/marketplace.schema.json",
"name": "make-no-mistakes",
"version": "1.9.0",
"version": "1.10.0",
"description": "The disciplined dev lifecycle — implement issues, review PRs, sync releases, test E2E, manage sessions, and stash secrets via OS-native prompts. One plugin to make no mistakes.",
"owner": {
"name": "Luis Andres Pena Castillo",
Expand All @@ -11,7 +11,7 @@
{
"name": "make-no-mistakes",
"description": "Dev lifecycle orchestrator: disciplined Linear issue execution with worktree isolation, PR review with Greptile gating, team release sync, E2E test generation and execution, test suite previewer, security pentesting, MoSCoW + RICE prioritization, cross-platform secret stash via OS-native GUI prompts (zenity / kdialog / osascript / Get-Credential), and session management. 18 commands, 6 auto-activating skills, 2 specialized agents.",
"version": "1.9.0",
"version": "1.10.0",
"author": {
"name": "Luis Andres Pena Castillo",
"email": "lapc506@users.noreply.github.com"
Expand Down
2 changes: 1 addition & 1 deletion .claude-plugin/plugin.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "make-no-mistakes",
"version": "1.9.0",
"version": "1.10.0",
"description": "The disciplined dev lifecycle — implement issues, review PRs, sync releases, test E2E, manage sessions, stash secrets, and enforce manifest-driven tool-call hooks. One plugin to make no mistakes.",
"author": {
"name": "Luis Andres Pena Castillo",
Expand Down
9 changes: 5 additions & 4 deletions hooks/lib/eval-rule.sh
Original file line number Diff line number Diff line change
Expand Up @@ -96,10 +96,11 @@ while [ "$i" -lt "$N_CONDITIONS" ]; do

# Resolve which input variable to inspect.
case "$FIELD" in
command) VALUE="$INPUT_COMMAND" ;;
file_path) VALUE="$INPUT_FILE_PATH" ;;
content) VALUE="$INPUT_CONTENT" ;;
text) VALUE="$INPUT_TEXT" ;;
command) VALUE="$INPUT_COMMAND" ;;
file_path) VALUE="$INPUT_FILE_PATH" ;;
content) VALUE="$INPUT_CONTENT" ;;
text) VALUE="$INPUT_TEXT" ;;
old_string) VALUE="$INPUT_OLD_STRING" ;;
*)
# Unknown field — treat as condition failure (rule won't fire).
exit 0
Expand Down
9 changes: 8 additions & 1 deletion hooks/lib/parse-input.sh
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ INPUT_COMMAND=""
INPUT_FILE_PATH=""
INPUT_CONTENT=""
INPUT_TEXT=""
INPUT_OLD_STRING=""

if command -v jq >/dev/null 2>&1; then
INPUT_COMMAND="$(printf '%s' "$INPUT_RAW" \
Expand All @@ -39,6 +40,12 @@ if command -v jq >/dev/null 2>&1; then
| jq -r '.tool_input.content // .tool_input.new_string // empty' 2>/dev/null || true)"
INPUT_TEXT="$(printf '%s' "$INPUT_RAW" \
| jq -r '.tool_input.text // .tool_input.message // .tool_input.content // empty' 2>/dev/null || true)"
# Edit / MultiEdit: expose tool_input.old_string. For MultiEdit, where
# old_string lives inside an `edits[]` array, flatten every old_string
# into a single newline-joined value so a single regex check covers
# both shapes. Empty for non-Edit tool calls.
INPUT_OLD_STRING="$(printf '%s' "$INPUT_RAW" \
| jq -r '.tool_input.old_string // ([.tool_input.edits[]?.old_string | strings] | join("\n")) // empty' 2>/dev/null || true)"
fi

export INPUT_RAW INPUT_COMMAND INPUT_FILE_PATH INPUT_CONTENT INPUT_TEXT
export INPUT_RAW INPUT_COMMAND INPUT_FILE_PATH INPUT_CONTENT INPUT_TEXT INPUT_OLD_STRING
38 changes: 37 additions & 1 deletion hooks/rules/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ Every rule is one YAML row with these fields:
description: <one-line> # required, shown in stderr on match
applies_to: [Bash | Edit | Write | MultiEdit | Slack] # required, non-empty
match: # required, non-empty array (AND-chain)
- field: command | file_path | content | text
- field: command | file_path | content | text | old_string
pattern: '<ERE regex>' # optional; if present, field MUST match
not_pattern: '<ERE regex>' # optional; if present, field must NOT match
flags: i # optional; only "i" (case-insensitive) supported
Expand Down Expand Up @@ -176,6 +176,42 @@ Adding a new family is fine — just keep ids unique and follow the schema.
Each rule ships a kebab-case bypass marker for the rare cases where
the action is intentional and documented.

- **Tier 2 — discipline (warn)**
(`warn-deletes-console-log`, `warn-time-estimates-in-plans`,
`warn-pr-create-many-files`, `warn-posthog-in-alerts`,
`block-sibling-suffix-storage`, `warn-localhost-in-pr-body`) — soft
guidelines from feedback memories that aren't outright errors but
degrade quality if accumulated. Each rule nudges the author toward
the documented pattern without blocking the operation. One exception:
`block-sibling-suffix-storage` uses `block` because the storage-layout
error is hard to undo once committed.
- `warn-deletes-console-log` flags Edits whose `old_string` removes a
debug-log call (`console.log(`, `console.debug(`, `console.error(`,
`debug(`, `logger.debug/info/trace(`) per
`feedback_never_delete_debug_logs.md` — gate via env var, never
delete.
- `warn-time-estimates-in-plans` flags writes to plan/spec/design files
that contain `X days/sprints/weeks/cycles` or their Spanish
equivalents per `feedback_no_time_estimates.md` — use sequential
ordering, not calendar dates.
- `warn-pr-create-many-files` is a heuristic on `gh pr create` that
nudges the caller to verify the diff has <=15 files before opening
(`feedback_split_large_prs.md` / DOJ-2482).
- `warn-posthog-in-alerts` (Slack `applies_to`) flags messages
mentioning `posthog`, `dashboard`, or `instrumentation` —
`feedback_no_posthog_nag.md` (Juan owns; out of scope for other POs).
- `block-sibling-suffix-storage` blocks CLI uploads that use the
discouraged sibling-suffix layout (`foo.processed.zip` next to
`foo.zip`); the documented layout uses `originals/` + `processed/`
subdirs (`feedback_explicit_storage_prefixes.md`).
- `warn-localhost-in-pr-body` flags `gh pr create` / `gh pr edit`
invocations whose inline `--body` mentions `localhost` or
`127.0.0.1` — staging at `dev.dojocoding.io` is the correct QA
target (`feedback_test_on_staging.md`).

`warn-deletes-console-log` is the first rule to use the new
`old_string` field exposed by `parse-input.sh` (see Schema below).

## Tier 2 — decomposing non-deterministic memories

Many narrative-style guidelines can be converted to deterministic rules
Expand Down
Loading
Loading