diff options
| author | Gabriel Schneider <[email protected]> | 2026-11-08 22:06:44 -0300 |
|---|---|---|
| committer | Gabriel Schneider <[email protected]> | 2026-11-08 22:06:44 -0300 |
| commit | d01ae88463261cc721f7338ef383c9265ac7071d (patch) | |
| tree | 1c4e24e4657b933296236fb23e456b93e71ea728 | |
| parent | 4c4fce7373ea72b10e8d9bb7aa3c91c3d5bbf0f5 (diff) | |
| download | pardes-d01ae88463261cc721f7338ef383c9265ac7071d.tar.gz pardes-d01ae88463261cc721f7338ef383c9265ac7071d.zip | |
helix: o on a line indented by less than a unit is a documented pardes choice, waived in words: helix's no-language indent_for_newline (helix-core/src/indent.rs:1361-1362, indent_level_for_line at 200-211) opens the line with whole units only, rounding two spaces down to none (and six to four, Enter the same, checked with hx-harness), where Enter, o and O keep the indent as it is, acme's autoindent (reference.typ's Indent row, change tlwwmyym); waivers.jsonl names o-partial-indent-drops (hxdiff 3 to 2), and helix-keys.md's o, Enter and waiver rows say it
Co-Authored-By: Claude Fable 5.1 <[email protected]>
Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge
| -rw-r--r-- | docs/helix-keys.md | 13 | ||||
| -rw-r--r-- | test/hxcases/waivers.jsonl | 1 |
2 files changed, 9 insertions, 5 deletions
diff --git a/docs/helix-keys.md b/docs/helix-keys.md index f517a7a8..c928d5ec 100644 --- a/docs/helix-keys.md +++ b/docs/helix-keys.md @@ -117,7 +117,7 @@ language-backend queries, and the shell pipe. | `zm` | scroll the unwrapped view so the cursor's column is in its middle | helix `align_view_middle`; with soft wrap on there is no horizontal scroll, and nothing happens | out of corpus (the harness's text never scrolls sideways) | | `i` `a` | insert at selection start / after selection end | helix semantics: `i` before the selection, `a` selects and appends after it | helix-verified | | `I` `A` | insert at first non-ws / line end | matches `insert_at_line_start` / `insert_at_line_end` | helix-verified | -| `o` `O` | open line below / above, copying the current line's indent levels; `<n>o` opens n | matches `open_below`/`open_above` | helix-verified | +| `o` `O` | open line below / above, with the current line's indent as it is (acme's autoindent, tabs and all); `<n>o` opens n | `open_below`/`open_above`, except that helix's no-language fallback rounds the indent down to whole units: under its 4-space unit, two spaces open a line with none (waiver `o-partial-indent-drops`) | helix-verified (whole units) / pardes-specific (partial) | | `v` | select (extend) mode: motions extend from the fixed anchor; `v` again exits KEEPING the selection | mode "select" is reported only while this is on (helix keeps mode normal for x/%/mi selections) | helix-verified | | `x` / `<n>x` | select current line / extend one (n) line(s) down, char-range through the newline, cursor ON the `\n` | col-0 vim-ism removed (phase 5); matches `extend_line_below`, mode stays normal | helix-verified | | `d` | delete selection (implicit or explicit); bare cursor = the 1-wide selection | always yanks (`Alt-d` noyank in B); terminals: drops typed runs only | helix-verified | @@ -141,7 +141,7 @@ language-backend queries, and the shell pipe. | `n` / `N` | next / previous match of the text's places when a query pane fed them (a `/`, a list's places in this text: refs, diagnostics, a Grep's hits), round the ends without a message; else the last search register's regex in the current text, as before; counts repeat | only the primary selection is replaced; in select mode each match is added and becomes primary. Named registers work. `*` sets the pattern from selections with word boundaries (`Alt-*` without) and seeds the text's query pane with it, the keyboard staying. The former Look ring is `LookNext` / `LookPrev`, `SPC j n` / `SPC j p`. PDFs retain their location-result navigation | helix-verified | | insert: printable text | file: real edit; terminal: typed run splice | | helix-verified (file) | -| insert: `Enter` | newline; keeps the current full indent levels and adds one 4-space logical tab when the text before the cursor ends in `(`, `[`, `{`, or `)` (including `})`) | plain lines match `insert_newline`; delimiter heuristic is pardes-specific | helix-verified (plain) / pardes-specific (delimiter) | +| insert: `Enter` | newline; keeps the current line's indent as it is and adds one 4-space logical tab (a tab where the indent is tabs) when the text before the cursor ends in `(`, `[`, `{`, or `)` (including `})`) | plain lines match `insert_newline` at whole indent units (helix drops a partial one, as for `o`); delimiter heuristic is pardes-specific | helix-verified (plain) / pardes-specific (partial indent, delimiter) | | insert: `Backspace` (+ `Shift-Backspace`) | delete prev char, joins lines at col 0; in a line's leading blanks, back to the previous 4-column indent stop (a whole unit when on one; a tab still goes alone) | matches `delete_char_backward` and its dedent; `Ctrl-h` alias in B | helix-verified | | insert: `Up` `Down` `Left` `Right` | move cursor | matches helix's "not recommended" insert arrows | helix-verified | | `gd` `gD` `gy` `gi` `gr` | LSP definition / declaration / type-definition / implementation / references. One answer jumps straight there; several (definition, implementation, references) fill the text's query pane, line 1 `Def`/`Impl`/`Refs`, their places in the text tinted and stepped by `n`/`N`; the others fill `+Search`, where `LookNext` / `LookPrev` walk and Enter opens | Ctrl+left-click is the mouse spelling of `gd`; language support depends on the configured backend | out of corpus | @@ -400,9 +400,12 @@ Files (all in `test/hxcases/`): (runs the `hx-harness` binary from the helix checkout; override with `$HX_HARNESS`). Only needed when cases change — the diff itself runs offline. -- `waivers.jsonl` — named exemptions, each with a reason. One live one: - `alt-c-window-op` (the pardes window op deliberately shadows helix - change-noyank). `wiX-edit-drops-sel` and `msel-append` went when insert +- `waivers.jsonl` — named exemptions, each with a reason, all deliberate + pardes choices: `alt-c-window-op` (the pardes window op shadows helix + change-noyank), `msel-ins-checkpoint` (undo restores the primary range + alone), `gc-noscroll` (`gc` runs Callstack), `o-partial-indent-drops` + (`o` keeps a partial indent, acme's autoindent, where helix rounds it + down to whole units). `wiX-edit-drops-sel` and `msel-append` went when insert mode began carrying every range through its edits, `msel-yank-paste` with registers of one value per range, `sel-regex-caret` and `sel-regex-dot-newline` when `s`/`S` began searching line by line. diff --git a/test/hxcases/waivers.jsonl b/test/hxcases/waivers.jsonl index 34687480..e4fe39e1 100644 --- a/test/hxcases/waivers.jsonl +++ b/test/hxcases/waivers.jsonl @@ -1,3 +1,4 @@ {"name":"alt-c-window-op","reason":"Alt-c moves a pane to a new column instead of Helix's change-noyank.","reference":{"name":"alt-c-window-op","text":"bc def\n","mode":"insert","cursor":{"row":0,"col":0},"anchor":{"row":0,"col":0}},"expected":{"name":"alt-c-window-op","text":"abc def\n","mode":"normal","cursor":{"row":0,"col":0},"anchor":{"row":0,"col":0}}} {"name":"msel-ins-checkpoint","reason":"Undo restores the primary range alone: a history entry keeps one range, not every one, so the others stay where the edit left them.","reference":{"name":"msel-ins-checkpoint","text":"Xab\nXab\n","mode":"normal","cursor":{"row":1,"col":1},"anchor":{"row":1,"col":1},"sels":[{"cursor":{"row":0,"col":1},"anchor":{"row":0,"col":1}},{"cursor":{"row":1,"col":1},"anchor":{"row":1,"col":1}}],"primary":1},"expected":{"name":"msel-ins-checkpoint","text":"Xab\nXab\n","mode":"normal","cursor":{"row":1,"col":1},"anchor":{"row":1,"col":1},"sels":[{"cursor":{"row":0,"col":2},"anchor":{"row":0,"col":2}},{"cursor":{"row":1,"col":1},"anchor":{"row":1,"col":1}}],"primary":1}} {"name":"gc-noscroll","reason":"gc runs the Callstack builtin at the cursor instead of moving to the viewport center; with no language server the cursor stays put.","reference":{"name":"gc-noscroll","text":"l00\nl01\nl02\nl03\nl04\nl05\nl06\nl07\nl08\nl09\nl10\nl11\n","mode":"normal","cursor":{"row":6,"col":0},"anchor":{"row":6,"col":0}},"expected":{"name":"gc-noscroll","text":"l00\nl01\nl02\nl03\nl04\nl05\nl06\nl07\nl08\nl09\nl10\nl11\n","mode":"normal","cursor":{"row":0,"col":0},"anchor":{"row":0,"col":0}}} +{"name":"o-partial-indent-drops","reason":"Enter, o and O keep the line's indent as it is, as acme's autoindent does (reference.typ, Indent), where helix's no-language fallback rounds it down to whole indent units, so two spaces under a 4-space unit open a line with none.","reference":{"name":"o-partial-indent-drops","text":" foo\n\n","mode":"insert","cursor":{"row":1,"col":0},"anchor":{"row":1,"col":0}},"expected":{"name":"o-partial-indent-drops","text":" foo\n \n","mode":"insert","cursor":{"row":1,"col":2},"anchor":{"row":1,"col":2}}} |
