fix repl-block, check-tangle, commands: READMEs, exit codes, path resolution
repl-block: - Listing mode exits 0, not 1 (listing is not an error) - Dead lines parameter removed from find_by_function - Block listing goes to stderr (not stdout) so piped use works - Added README.org check-tangle: - Fixed tangle tool resolution: prefer local projects/tangle-tool/tangle - Fixed path resolution for relative and absolute tangle paths - Removed 2>/dev/null suppression so tangle errors are visible - Added README.org Commands: - Rewrote all three .opencode/commands/*.md with proper prompts
This commit is contained in:
@@ -3,6 +3,9 @@ description: Check paren balance in lisp blocks of .org files
|
||||
---
|
||||
|
||||
Run `projects/check-parens/check-parens` on the given .org files to verify all
|
||||
`#+begin_src lisp` blocks have balanced parentheses.
|
||||
`#+begin_src lisp` blocks have balanced parentheses. Uses SBCL's reader for
|
||||
100% accuracy — no false positives from string literals or character literals.
|
||||
|
||||
Exit 0 if all blocks balanced, 1 if any issues found.
|
||||
|
||||
Usage: /check-parens <file.org> [<file.org> ...]
|
||||
|
||||
@@ -3,6 +3,13 @@ description: Tangle an org file and compile the result
|
||||
---
|
||||
|
||||
Tangle an .org file to .lisp then compile with SBCL. Reports the first
|
||||
compile error. Exit 0 = clean, exit 1 = compilation error.
|
||||
compile error with line numbers. Exit 0 = clean compile, exit 1 = error.
|
||||
|
||||
Prepares code for commit by ensuring the tangled .lisp file is syntactically
|
||||
valid. Catches missing symbols, undefined functions, and type errors before
|
||||
they reach the running daemon.
|
||||
|
||||
Usage: /check-tangle <file.org>
|
||||
|
||||
Example:
|
||||
/check-tangle projects/passepartout/org/channel-tui-main.org
|
||||
|
||||
@@ -2,12 +2,16 @@
|
||||
description: Send a lisp block from an org file to the REPL
|
||||
---
|
||||
|
||||
Extract a `#+begin_src lisp` block from an .org file and send it to the
|
||||
running daemon REPL.
|
||||
Extract a `#+begin_src lisp` block from an .org file and pipe it to the
|
||||
running daemon REPL. Identify the block by function name or index.
|
||||
|
||||
The `--package` flag wraps the block in `(in-package ...)` so it evaluates
|
||||
in the right namespace — essential when the block references symbols from
|
||||
a specific package without the package prefix.
|
||||
|
||||
Usage: /repl-block <file.org> --function <name>
|
||||
/repl-block <file.org> --block <number>
|
||||
/repl-block <file.org> --function <name> --package <pkg>
|
||||
/repl-block <file.org> --block <number>
|
||||
|
||||
The --package flag wraps the block in an (in-package ...) form.
|
||||
Use --block to identify by 1-based index, --function to find by defun name.
|
||||
Example:
|
||||
/repl-block projects/passepartout/org/channel-tui-view.org --function view-status --package :passepartout.channel-tui
|
||||
|
||||
Reference in New Issue
Block a user