66 Commits

Author SHA1 Message Date
lucaronin
07edfac400 feat: support mounted vault workspaces 2026-05-11 18:21:12 +02:00
lucaronin
b384cbf6ee chore: enforce main-only workflow and adopt AGENTS.md 2026-04-07 18:42:41 +02:00
lucaronin
95edc7f1a2 docs: require completion comment on Todoist task before /laputa-done (QA, refactoring, ADRs, code health) 2026-04-06 16:17:19 +02:00
lucaronin
8fe5340416 docs: require pre-task code health check — refactor before feature work if below gate 2026-04-06 16:12:58 +02:00
lucaronin
ca507f6796 fix: forbid lowering CodeScene thresholds in CLAUDE.md 2026-04-06 15:45:20 +02:00
lucaronin
3411f4e817 fix: stabilize flaky SearchPanel keyboard tests with act() wrapping
Wrap fireEvent.keyDown calls in act() and assertions in waitFor() so
React state updates flush before checking side effects.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-06 14:41:59 +02:00
lucaronin
49df920ae2 docs: add mandatory UI components rules to CLAUDE.md — always use shadcn/ui, never raw HTML 2026-04-04 09:56:30 +02:00
lucaronin
f89904620a docs: task not done until git push succeeds — fix pre-push failures before marking done 2026-03-31 12:27:53 +02:00
lucaronin
ee41060f00 docs: compress CLAUDE.md (176 → 130 lines) — remove garbled section, deduplicate QA scripts 2026-03-31 02:01:29 +02:00
lucaronin
72b1562480 docs: require Todoist comments on every task state transition 2026-03-30 18:15:51 +02:00
lucaronin
084820cb79 docs: Playwright only for core flows, < 10 min budget, cosmetic changes use Vitest 2026-03-30 17:48:05 +02:00
lucaronin
56ceee20e9 docs: QA phase 2 uses pnpm tauri dev instead of DMG, remove Brian review phase 2026-03-30 17:43:43 +02:00
lucaronin
f595ee95c3 feat: ratchet CodeScene thresholds — never regress, auto-update on each push 2026-03-30 17:40:52 +02:00
lucaronin
f9f48bd166 docs: simplify product rules — remove keyboard-first/retrocompat (spec responsibility), clarify vault usage 2026-03-30 17:33:22 +02:00
lucaronin
bb5fa2880f feat: add /laputa-next-task and /laputa-done slash commands, clean CLAUDE.md 2026-03-30 17:28:21 +02:00
lucaronin
e7a5ee1cad docs: add native app QA phase to CLAUDE.md (Claude Code tests before Brian) 2026-03-30 17:23:58 +02:00
lucaronin
86569800c9 docs: clarify task pickup priority in CLAUDE.md, simplify self-dispatch (no skip logic) 2026-03-30 17:21:00 +02:00
lucaronin
2a88681c28 docs: restructure CLAUDE.md into 4 clear sections (workflow/process/product/reference) 2026-03-30 17:18:10 +02:00
lucaronin
9d4736c856 feat: Claude Code self-dispatches next task autonomously after each completion 2026-03-30 17:02:12 +02:00
lucaronin
c9715d7570 docs: ADR timing rule — create in same commit as code, never before 2026-03-28 18:51:23 +01:00
lucaronin
82d3c60f55 docs: forbid vault modifications for testing — use demo-vault-v2 only 2026-03-28 18:25:23 +01:00
lucaronin
1e004e4abe docs: add /create-adr Claude Code command + slim ADR section in CLAUDE.md
- .claude/commands/create-adr.md: full template, ID numbering, superseding flow, best practices
- CLAUDE.md: ADR section now delegates to /create-adr for how-to details
2026-03-28 10:21:42 +01:00
lucaronin
04ff69a657 docs: slim ADR section in CLAUDE.md (format lives in README)
fix: SearchPanel test — fireEvent.keyDown on window not document
chore: ignore src-tauri/gen/ in eslint flat config (Tauri iOS generated files)
2026-03-28 10:18:06 +01:00
lucaronin
c909870e3e docs: add Architecture Decision Records (ADRs) — 5 backfill + process in CLAUDE.md
- docs/adr/README.md: format spec, rules, index
- 0001: Tauri v2 + React stack
- 0002: filesystem as source of truth
- 0003: single note model (no tabs)
- 0004: vault vs app settings storage
- 0005: Tauri iOS for iPad (vs SwiftUI)
- CLAUDE.md: ADR process — when to read, when to create, when to supersede
2026-03-28 10:05:23 +01:00
lucaronin
ad9d0e5e67 refactor: RelationshipsPanel — extract shared hooks to reduce complexity (avg: 9.36, gate: 8.90 → 9.31)
Extract useSearchKeyboard, useCreateAndOpen, and useCreateOption hooks from
duplicated logic in InlineAddNote, NoteTargetInput, and AddRelationshipForm.
File score: 7.8 → 8.48. Raise average code health gate threshold to 9.31.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-25 09:46:15 +01:00
lucaronin
63054f7eb9 docs: add Boy Scout Rule to CLAUDE.md — leave every touched file better than found 2026-03-24 15:58:23 +01:00
lucaronin
e47625f8bb ci: add Average Code Health gate (≥8.9 floor, target 9.5) to CI, pre-commit, pre-push
- Both hotspot (≥9.5) and average (≥8.9) gates now block commit/push/CI
- Current average: 8.97 — threshold set at 8.9 to block regressions without
  blocking the current state; aspirational target remains 9.5
- pre-commit: replaced phantom pre_commit_code_health_safeguard with real inline check
- pre-push: CodeScene step is now blocking (was informational-only)
- CLAUDE.md: explicit instructions to monitor both scores via MCP CodeScene
2026-03-24 15:47:31 +01:00
lucaronin
75ad88fb54 docs: require explicit Todoist move to In Review in task completion flow
Claude Code must move task to In Review via API before firing done signal.
Fixes silent failure where tasks stayed In Progress after completion.
2026-03-18 13:08:53 +01:00
lucaronin
0897cc5d95 docs: update CLAUDE.md — CodeScene threshold 9.2/9.2, fix port/finish-signal for no-worktree workflow 2026-03-17 22:01:26 +01:00
lucaronin
dec9fe6412 docs: add Kent Beck Test Desiderata to TDD section in CLAUDE.md 2026-03-17 21:35:47 +01:00
lucaronin
42f27eeb9b docs: compress CLAUDE.md 360→93 lines — remove verbose explanations, keep rules
Removed: TDD rationale paragraphs, Phase 1 QA bullet lists (Claude infers from context),
verbose Vault Retrocompatibility pattern, design file node commands, menu bar structure
explanation, Push Workflow verbose anti-PR rationale.

Kept: all concrete rules, checklist commands, thresholds, scripts, gotchas.
2026-03-13 19:56:49 +01:00
lucaronin
2b33536a68 docs: convert remaining ASCII diagrams to Mermaid + add Mermaid rule to CLAUDE.md
ARCHITECTURE.md:
- System Overview → flowchart (React Frontend / Rust Backend / External Services)
- MCP Server Architecture → flowchart (index.js, vault.js, ws-bridge, transports)
- WebSocket Bridge → flowchart LR (Frontend ↔ ws-bridge ↔ vault)
- Vault Cache Three Strategies → flowchart (full scan / incremental / cache hit)
- Auto-Save Flow → flowchart LR
- Git Sync Flow → flowchart TD (auto-sync + manual commit paths)

CLAUDE.md:
- Added 'Documentation Diagrams' section: Mermaid preferred for all new diagrams,
  convert ASCII on sight, exception for spatial wireframe layouts
2026-03-13 19:22:36 +01:00
lucaronin
3d5423a4c2 docs: add Phase 1b — Tauri dev QA for filesystem/native tasks
Claude Code must also test with pnpm tauri dev (not just Playwright)
when the task touches: filesystem, AI context pipeline, MCP server,
git integration, or native Tauri commands.

Playwright tests mock-tauri handlers — they cannot catch bugs in the
real file read/write layer. Phase 1b closes this gap.

Lesson from ai-chat-empty-body: bug was in MCP server reading from disk,
invisible to Playwright. Phase 1b would have caught it in attempt 1.
2026-03-08 21:52:30 +01:00
lucaronin
dd7f0f978a docs: strengthen Phase 1 QA requirements in CLAUDE.md
- Require Claude Code to write a new task-specific Playwright test for
  every task (not just run existing smoke tests)
- Test must fail before fix and pass after — proves coverage
- Clarify that Phase 1 is Claude Code's quality gate, not Brian's
- Brian's Phase 2 is a reinforcement check; if he finds a bug that
  Phase 1 should have caught, that is a Phase 1 failure

Lesson from ai-chat-empty-body: 5 QA cycles happened because Phase 1
never verified that the AI actually received note content end-to-end.
2026-03-08 20:54:44 +01:00
lucaronin
d3a2951bc7 docs: update ARCHITECTURE, ABSTRACTIONS, GETTING-STARTED to reflect current codebase
Updated all three docs to reflect significant features added since they were last written:
- AI agent panel (Claude CLI subprocess with tool execution + NDJSON streaming)
- Vault cache system (git-based incremental caching in cache.rs)
- Theme system (vault-based themes, useThemeManager, ThemePropertyEditor)
- Search & indexing (qmd integration, keyword/semantic/hybrid modes)
- Pulse view (git activity feed with pagination)
- GitHub OAuth (device flow, vault clone/create)
- Vault management (multi-vault, vault config, onboarding, WelcomeScreen)
- Raw editor mode (CodeMirror 6 alternative)
- Command palette (Cmd+K registry)
- Auto-sync & conflict resolution

Also added mandatory docs-update rule to CLAUDE.md: docs/ files must be
updated in the same commit as significant feature changes.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-07 04:09:23 +01:00
lucaronin
b0b0464f99 feat: add Playwright smoke test infrastructure for task-scoped QA
Adds headless Chromium smoke tests that run before push, catching
UI/UX bugs before Brian QA. Includes shared helpers for command
palette and keyboard shortcut testing.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-06 09:39:20 +01:00
lucaronin
c876997fba docs: add mandatory Playwright Phase 1 QA step before laputa-task-done
Claude Code must now run Playwright smoke tests against the dev server
before firing the done signal. This catches UI/UX bugs (missing Cmd+K
commands, broken shortcuts, layout issues) before Brian's native QA.

- Phase 1 (Playwright, headless) = Claude Code's responsibility
- Phase 2 (native Tauri, keyboard-only) = Brian's responsibility

Phase 1 covers: command palette entries, keyboard shortcuts, Tab
navigation, UI state changes. Phase 2 covers: file system, git, native
Tauri behaviors that can't run in the browser.
2026-03-06 08:36:01 +01:00
lucaronin
81990f0292 docs: never open PRs — push directly to main always 2026-03-02 12:03:31 +01:00
lucaronin
01d827fb5c docs: add keyboard-first principle — every feature must be testable without mouse 2026-03-01 12:15:06 +01:00
lucaronin
3d0b4935de docs: require QA on pnpm tauri dev, not browser mode 2026-02-28 23:47:56 +01:00
lucaronin
d202268ed3 perf: optimize pre-push hook from ~12min to ~30s
- Add --no-clean to cargo llvm-cov for incremental builds (~5s vs ~8min)
- Skip Rust checks when no src-tauri/ files changed
- Merge redundant frontend test + coverage into single coverage step
- Reorder: fast lints (fmt, clippy) before slow coverage for quick feedback
- Add timing output and LAPUTA_FULL_COVERAGE=1 escape hatch

Expected: frontend-only push ~1 min, frontend+Rust ~2-3 min
2026-02-27 15:53:05 +01:00
lucaronin
91cff383f3 ci: replace remote CI with local pre-push hook
All checks now run locally via .husky/pre-push before any push.
This eliminates GitHub Actions queue, runner saturation, and
'waiting for status' blocks entirely.

Hook runs: tsc, Vite build, frontend tests, frontend coverage (≥70%),
Rust coverage (≥85%), Clippy, rustfmt, CodeScene (≥9.2).

Claude Code is explicitly forbidden from using --no-verify (documented
in CLAUDE.md). Branch protection required status checks removed.
Remote CI kept as non-blocking safety net only.
2026-02-27 15:29:51 +01:00
lucaronin
4224a918ed docs: update design workflow — light mode, frame layout, cleanup on merge 2026-02-25 22:04:23 +01:00
lucaronin
0d6b285709 feat: raise CodeScene code health threshold to 9.2
The project currently scores ~9.33, so raising the CI gate from 8.45
to 9.2 prevents significant regressions while leaving headroom.
Updates both the CI workflow threshold and CLAUDE.md documentation.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-24 15:06:24 +01:00
lucaronin
941c4c78e6 refactor: rewrite CLAUDE.md (107 lines, critical rules first) + add pre-commit hook 2026-02-23 22:33:11 +01:00
lucaronin
75b9d9c80e docs: CI is a safety net, not discovery — enforce local checks before pushing 2026-02-23 22:27:11 +01:00
lucaronin
35f34a5551 docs: no CI gate shortcuts — fix structural problems, not symptoms 2026-02-23 21:49:29 +01:00
lucaronin
ac362ef9c6 docs: two-stage QA protocol — lockfile + native app on ~/Laputa 2026-02-23 21:33:41 +01:00
lucaronin
e968d2b3f2 docs: strengthen QA requirements — native app on real vault mandatory for all tasks 2026-02-23 21:25:32 +01:00
lucaronin
6e8c7a63d8 docs: fix design file instructions — additive only, no cp ui-design.pen 2026-02-23 20:11:09 +01:00