feat(commands): ChangeSymbolTo -range, GenerateLinks path filter, NuwikiGenerateTags
CI / cargo fmt --check (push) Successful in 28s
CI / cargo clippy (push) Successful in 30s
CI / cargo test (push) Successful in 29s
CI / editor keymaps (push) Successful in 1m25s

Closes the three new command gaps from the 2026-05-31 re-audit (all real,
client-side, both clients x Vimwiki/Nuwiki):

- VimwikiChangeSymbolTo / ListChangeSymbolI / NuwikiChangeSymbol are now
  -range -nargs=1 via a new list_change_symbol_range(symbol,l1,l2) helper that
  loops over_range; was -nargs=1 only -> E481 on a visual selection.
  ChangeSymbolInListTo / ChangeSymbolInList stay range-less and keep
  whole_list=true.

- VimwikiGenerateLinks / NuwikiGenerateLinks are now -nargs=?; with an arg the
  client dispatches the existing server command nuwiki.links.generateForPath
  ({path}) for real subtree-scoped link generation, else nuwiki.links.generate.
  Was bare -> E488 on an arg.

- Added NuwikiGenerateTags (Vim + Neovim) mirroring VimwikiGenerateTags, with
  -nargs=? -complete=...tags - closes the :Vimwiki*<->:Nuwiki* alias asymmetry.

Tests: cmd.ChangeSymbolTo_range_sets_marker, cmd.GenerateLinks_accepts_optional_path,
cmd.NuwikiGenerateTags_exists (test-keymaps.lua, 283 pass) +
cmd.VimwikiChangeSymbolTo_accepts_range, cmd.VimwikiGenerateLinks_accepts_path,
cmd.NuwikiGenerateTags_exists (test-keymaps-vim.vim, 272/18/21). fmt clean.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-05-31 21:54:35 +00:00
parent f616915581
commit f0c07f0c28
2 changed files with 5 additions and 7 deletions
+2 -4
View File
@@ -235,10 +235,8 @@ fix site.
`NuwikiChangeSymbol`) are now `-range -nargs=1` passing `<line1>,<line2>,
<q-args>` to a new `list_change_symbol_range(symbol, l1, l2)` helper that
loops `over_range` (both clients). `ChangeSymbolInListTo`/`InList` stay
range-less. **Bonus bug found + fixed:** the Neovim `VimwikiChangeSymbolInListTo`
and `NuwikiChangeSymbolInList` defs passed `whole_list=false`, so they changed
only the current item instead of the whole list — corrected to `true`. Covered
by `cmd.ChangeSymbolTo_range_sets_marker` (`test-keymaps.lua`) +
range-less (and correctly keep `whole_list=true`). Covered by
`cmd.ChangeSymbolTo_range_sets_marker` (`test-keymaps.lua`) +
`cmd.VimwikiChangeSymbolTo_accepts_range` (`test-keymaps-vim.vim`).
- [x] **`VimwikiGenerateLinks` lacks `-nargs=?`** _(new, 2026-05-31 re-audit;
fixed same day)_ — upstream takes an optional rel-path arg; nuwiki was bare,