Skip to content

Commit 158a94f

Browse files
committed
feat(mini.nvim): sync
1 parent 4163b49 commit 158a94f

File tree

2 files changed

+5
-6
lines changed

2 files changed

+5
-6
lines changed

mini.nvim/CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -157,6 +157,8 @@ There are following change types:
157157

158158
- Stop creating `update_n_lines` mapping: it occupies "mapping real estate" while being rarely needed and straightforward to create manually using `MiniSurround.update_n_lines()`.
159159

160+
- Automatically map `s` key to `<Nop>` if any of created mappings start with it. This prevents accidental trigger of built-in `s` if there is a long delay between pressing "s" and the next key.
161+
160162
### Refine {#v0.17.0-mini.surround-refine}
161163

162164
- Update `gen_spec.inpuf.treesitter()` to have `use_nvim_treesitter = false` as default option value (instead of `true`). It used to implement more advanced behavior, but as built-in `vim.treesitter` is capable enough, there is no need in extra dependency. The option will be removed after the release.

mini.nvim/doc/mini-surround.qmd

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -704,12 +704,9 @@ Module setup
704704
By default it uses "prefix style" left hand side starting with "s" (for
705705
"surround"): `sa` - "surround add", `sd` - "surround delete", etc.
706706

707-
Note: if 'timeoutlen' is low enough to cause occasional usage of [s](https://neovim.io/doc/user/helptag.html?tag=s) key
708-
(that deletes character under cursor), disable it with the following call:
709-
710-
```lua
711-
vim.keymap.set({ 'n', 'x' }, 's', '<Nop>')
712-
```
707+
Note: if any of the mappings start with "s" (as is by default), it is mapped
708+
to [<span class="help-syntax-keys">\<Nop\></span>](https://neovim.io/doc/user/helptag.html?tag=<Nop>) to prevent accidental trigger of built-in [s](https://neovim.io/doc/user/helptag.html?tag=s) (can happen if there
709+
is a long enough delay between pressing "s" and the next key). Use `cl` instead.
713710

714711
#### Custom surroundings {#minisurround.config-customsurroundings}
715712

0 commit comments

Comments
 (0)