diff options
Diffstat (limited to 'docs')
| -rw-r--r-- | docs/typ/reference.typ | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/docs/typ/reference.typ b/docs/typ/reference.typ index efc08a9b..f094a224 100644 --- a/docs/typ/reference.typ +++ b/docs/typ/reference.typ @@ -699,19 +699,25 @@ open file whose line matches. Commands: step puts both back, and unsaved edits are asked about once; the file takes no other command in that Edit. `r` reads a file over dot. `w` writes all of it, or the address, to its file or a name; all of it to its own - name leaves it clean. `f` names the pane and prints its line. File names + name leaves it clean. A `w` to its own file changed on disk since it was + read is refused once, as #word("Save") is (`modified on disk since read (w + again to overwrite)`), and the next `w` writes it; in an `X` the other + files are written, and the refusal names those it left. `f` names the pane and prints its line. File names are relative to the file's directory, and `~` is the home directory. - `<cmd` replaces dot with what `cmd` writes, `|cmd` pipes dot through it, `>cmd` sends dot to it and prints what it writes. Each command runs in its file's directory through #word("Shell"), off the -loop, so the editor goes on. The write that ran the Edit is held and +loop, so the editor goes on, with what a pane's command is given: +`$PARDES_MOUNT`, `$PARDES_9P`, `$PARDES_PID`, and `$winid` the Edit's pane. The write that ran the Edit is held and answered when they are done, its connection serving other requests meanwhile (a command may read the session through its mount); a flush of that write (an interrupted writer) kills the commands and changes nothing. Such an Edit is a write of its own: one with other lines is refused before any runs. One Edit's commands run at a time in a session, at most 1024 of -them. A command that fails (an exit status, 10 seconds, 1 MiB of output) +them. While they run, an Edit with no commands runs as usual unless it +would change, undo, rename, close or write a file the running one changes; +that, and a second Edit with commands, is refused `busy` (EBUSY). A command that fails (an exit status, 10 seconds, 1 MiB of output) fails the Edit, its stderr in `+Errors`. Each file's changes are one undo step, applied only if every command succeeds; a failure changes nothing and fails the write with acme's words (`Edit: no substitution`), as does a file edited while the |
