VSCodeVim / VSCodeVim/Vim

[FR] Set a threshold for the small delete register

Open
#8,216 0 comments 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
15.2k
Forks
1.5k
Avg merge
3d 18h
Merged PRs (30d)
6

Description

Hi,

What

I'd like an option that does something like this - basically an option vim.smalldeletethreshold with the values:

  • line: Standard vim behavior
  • multichar: Everything but single-char deletion goes into the numbered registers
  • (optional) off: There is no small delete threshold. Everything is in the numbered registers, even Del, x, etc.
Why

Standard vim behavior annoys me to no end because it's simply not how my brain works. Why should rearranging this:

[
  "a",
  "b",
  "c",
  ...
]

be different from rearranging this:

["a", "b", "c", ...]
How

To my amateur eye that seems easy enough to implement in register.ts but I might be wrong.

  1. Does an extension like this violate some VSCodeVim principle regarding vim compatibility?
  2. Would you add something like this?
  3. Would you accept a PR? Is there anything I'd have to do besides following the checklist in configuration.ts? I've never done anything with VSCode extensions. :)

Best regards,
Stefan

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with src/register/register.ts around the referenced deletion handling and src/configuration/configuration.ts around the option declarations. Read the linked PR to understand the proposed small-delete behavior and verify how VSCodeVim handles Vim-compatibility decisions. Done means a documented configuration option supports the agreed threshold values and deletion behavior is covered by appropriate tests.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
tooling
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.