Pasting over a selection doesn't work while useSystemClipboard is true.
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 15.2k
- Forks
- 1.5k
- Avg merge
- 3d 18h
- Merged PRs (30d)
- 6
Description
Describe the bug
If useSystemClipboard is set true, pasting over a selection will yank the selection, but not replace it.
To Reproduce
Steps to reproduce the behavior:
- Visually select lines in a buffer using
shift-V(and optionally movement keys) - Copy the selection with
y - Visually select the block you want to replace using
shift-V - Paste over the selection with
p - Nothing Appears to happen
- Move your curser to a new line
- Paste in normal mode with
p - You'll see the previous attempt to paste successfully yanked
Expected behavior
Step 5 should have pasted the first selected text block. Step 8 works as expected.
Screenshots
Current Behavior (vim.useSystemClipboard: true)

Expected Behavior (vim.useSystemClipboard: false)

Environment (please complete the following information):
- Extension (VsCodeVim) version: 1.8.1
- VSCode version: 1.35.0
- OS: macOS Mojave 10.14.5
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
No file or test is named. Reproduce the issue in VSCodeVim with useSystemClipboard enabled, then trace visual-mode p handling and the clipboard/yank path. Done means pasting over a visual selection replaces that selection and a later normal-mode paste still uses the expected text.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript, vscode
- Domain
- tooling
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100