From 8a7112f08e0ce93a37b177e3aa83637e1691b451 Mon Sep 17 00:00:00 2001 From: Gabriel Schneider Date: Fri, 31 Jul 2026 01:18:53 -0300 Subject: Look and Exec are builtins like any other MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Their only special feature is now the keys they are assigned. `Look main.zig` typed in a tag is the same look a right click is; config.look_cmd/exec_cmd point the two buttons and Enter/Tab at them, so retargeting Enter to Grep is one line. actOnSelection — a hand-written cascade with the builtin dispatch nested inside it — is gone, and the `button` parameter it threaded through five KEYBOARD call sites went with it. New syntax, spelled once in config.zig: @`ls -la` names a command to run rather than a file to open. Word expansion takes the quoted run whole, the way acme does for its own words, so a click inside one does not hand Look the fragment `ls`. And it nests: @`Look .` unwraps, re-enters the dispatcher, and looks at the directory. Guarded at depth 8, which is unreachable today (every re-entry strips a word or a delimiter pair, so the string strictly shrinks) and exists for a future syntax that does not shrink. leader_path is now optional: a builtin may have no SPC path when its shortcut is a key and a mouse button. New golden cmdword; the other 59 unmoved. --- test/snapshots/cmdword.golden | 217 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 217 insertions(+) create mode 100644 test/snapshots/cmdword.golden (limited to 'test/snapshots/cmdword.golden') diff --git a/test/snapshots/cmdword.golden b/test/snapshots/cmdword.golden new file mode 100644 index 00000000..03e272be --- /dev/null +++ b/test/snapshots/cmdword.golden @@ -0,0 +1,217 @@ +== snap opened grid=120x30 cursor=7,2 +|Kill Newcol Tutor Debug NextColor Dump Find Grep Help +| NOR /tmp/pardes-snap/cmdword/cwd/cmds.txt Save Del NOR /tmp/pardes-snap/cmdword/cwd Del +| 1 @`echo ZZ''E` @`echo ZZ''L` Look p.txt @`Look .` +| cmds.txt p.txt zzmark.txt +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +== snap atexec grid=120x30 cursor=7,2 +|Kill Newcol Tutor Debug NextColor Dump Find Grep Help +| NOR /tmp/pardes-snap/cmdword/cwd/cmds.txt Save Del NOR /tmp/pardes-snap/cmdword/cwd Del +| 1 @`echo ZZ''E` @`echo ZZ''L` Look p.txt @`Look .` +| cmds.txt p.txt zzmark.txt +| +| ZZE +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +== snap atlook grid=120x30 cursor=64,8 +|Kill Newcol Tutor Debug NextColor Dump Find Grep Help +| NOR /tmp/pardes-snap/cmdword/cwd/cmds.txt Save Del NOR /tmp/pardes-snap/cmdword/cwd Del +| 1 @`echo ZZ''E` @`echo ZZ''L` Look p.txt @`Look .` +| cmds.txt p.txt zzmark.txt +| +| ZZE +| +| ZZL +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +| +== snap lookword grid=120x30 cursor=7,17 +|Kill Newcol Tutor Debug NextColor Dump Find Grep Help +| NOR /tmp/pardes-snap/cmdword/cwd/cmds.txt Save Del NOR /tmp/pardes-snap/cmdword/cwd Del +| 1 @`echo ZZ''E` @`echo ZZ''L` Look p.txt @`Look .` +| cmds.txt p.txt zzmark.txt +| +| ZZE +| +| ZZL +| +| +| +| +| +| +| +| +| NOR /tmp/pardes-snap/cmdword/cwd/p.txt Save Del +| 1 just text +| +| +| +| +| +| +| +| +| +| +| +| +== snap nested grid=120x30 cursor=64,10 +|Kill Newcol Tutor Debug NextColor Dump Find Grep Help +| NOR /tmp/pardes-snap/cmdword/cwd/cmds.txt Save Del NOR /tmp/pardes-snap/cmdword/cwd Del +| 1 @`echo ZZ''E` @`echo ZZ''L` Look p.txt @`Look .` +| cmds.txt p.txt zzmark.txt +| +| ZZE +| +| ZZL +| +| cmds.txt p.txt zzmark.txt +| +| +| +| +| +| +| NOR /tmp/pardes-snap/cmdword/cwd/p.txt Save Del +| 1 just text +| +| +| +| +| +| +| +| +| +| +| +| +== snap execword grid=120x30 cursor=102,1 +|Kill Newcol Tutor Debug NextColor Dump Find Grep Help +| NOR /tmp/pardes-snap/cmdword/cwd/cmds.txt Save Del INS /tmp/pardes-snap/cmdword/cwd Del Exec +| 1 @`echo ZZ''E` @`echo ZZ''L` Look p.txt @`Look .` +| cmds.txt p.txt zzmark.txt +| +| ZZE +| +| ZZL +| +| cmds.txt p.txt zzmark.txt +| +| +| +| +| +| +| NOR /tmp/pardes-snap/cmdword/cwd/p.txt Save Del +| 1 just text +| +| +| +| +| +| +| +| +| +| +| +| +== snap tagcmd grid=120x30 cursor=116,1 +|Kill Newcol Tutor Debug NextColor Dump Find Grep Help +| NOR /tmp/pardes-snap/cmdword/cwd/cmds.txt Save Del INS /tmp/pardes-snap/cmdword/cwd Del Exec @`echo ZZ''T` +| 1 @`echo ZZ''E` @`echo ZZ''L` Look p.txt @`Look .` +| cmds.txt p.txt zzmark.txt +| +| ZZE +| +| ZZL +| +| cmds.txt p.txt zzmark.txt +| +| ZZT +| +| +| +| +| NOR /tmp/pardes-snap/cmdword/cwd/p.txt Save Del +| 1 just text +| +| +| +| +| +| +| +| +| +| +| +| -- cgit v1.3