diff --git a/.gitignore b/.gitignore index 5d97f1c..04d5eba 100644 --- a/.gitignore +++ b/.gitignore @@ -5,3 +5,4 @@ scripts/.env luacov.stats.out luacov.report.out .luacov.stats.*.out +.serena/ diff --git a/.strap/.gitignore b/.strap/.gitignore new file mode 100644 index 0000000..78c818a --- /dev/null +++ b/.strap/.gitignore @@ -0,0 +1,2 @@ +index.db +runs/ diff --git a/.strap/flows/regression.toml b/.strap/flows/regression.toml new file mode 100644 index 0000000..f8ad8ae --- /dev/null +++ b/.strap/flows/regression.toml @@ -0,0 +1,26 @@ +# nyan.nvim regression flow: lint + plenary suite; on red, an agent gets the +# failure plus relevant lessons and must make `make lint && make test` pass. + +[[step]] +name = "lint" +kind = "run" +cmd = "make lint" +on_fail = "fix" + +[[step]] +name = "test" +kind = "run" +cmd = "make test" +on_fail = "fix" + +[[step]] +name = "fix" +kind = "agent" +agent = "claude" +cmd = "claude -p --allowedTools 'Edit Read Glob Grep Bash' --max-turns 25" +tags = ["regression", "lua", "nvim"] +verify = "make lint && make test" +timeout_secs = 900 + +[trigger] +on = ["manual", "agent-finished"] diff --git a/.strap/lessons/msqks7ac.md b/.strap/lessons/msqks7ac.md new file mode 100644 index 0000000..0654254 --- /dev/null +++ b/.strap/lessons/msqks7ac.md @@ -0,0 +1,11 @@ ++++ +id = "msqks7ac" +tags = ["lua", "nvim", "debugger"] +confidence = 0.6 +helped = 0 +harmed = 0 +created = "2026-08-12T21:02:24.228836Z" +last_confirmed = "2026-08-12T21:02:24.228836Z" ++++ + +no lua adapter exists for mcp-debugger (strap debug); plugin lua runs inside nvim anyway — debug via the 2s plenary suite plus nvim --headless -c 'lua ...' state dumps; OSV via a generic-DAP MCP tool is the upgrade path if step-debugging ever matters diff --git a/.strap/tools.toml b/.strap/tools.toml new file mode 100644 index 0000000..13dfe2c --- /dev/null +++ b/.strap/tools.toml @@ -0,0 +1 @@ +# managed tools — see `strap tool add` diff --git a/AGENTS.md b/AGENTS.md new file mode 100644 index 0000000..3a7641d --- /dev/null +++ b/AGENTS.md @@ -0,0 +1,25 @@ +# nyan.nvim + +Neovim plugin (Lua). Plenary test suite, stylua formatting, luacheck static +analysis. + +## Build and test + +```bash +make test # plenary suite under headless nvim (~2s) +make lint # stylua --check +make lint-luacheck # luacheck static analysis +make format # apply stylua +make ci # full local CI parity: lint + luacheck + test +``` + +## Harness + +This project uses strap (per-project agent harness). Start tasks with +`strap lesson search "" --json`; record non-obvious learnings with +`strap lesson add "..." --tag lua --tag nvim`; close the loop with +`strap lesson feedback --helped|--harmed`. See `strap --help`. + +The `regression` flow (lint + tests, agent fix on red, `make lint && make test` +as ground truth) runs after each Claude Code session via the Stop hook in +`.claude/settings.json`; run it manually with `strap flow run regression`. diff --git a/CLAUDE.md b/CLAUDE.md new file mode 100644 index 0000000..43c994c --- /dev/null +++ b/CLAUDE.md @@ -0,0 +1 @@ +@AGENTS.md