You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In ex commands, you can use . to refer to the current line. So :5,.d means "delete everything between the 5th and current line (inclusive)." The dot doesn't work with the copy Ex command. It does, however, work with other commands, such as move and delete.
Also, ., -, and + work as long as they don't appear tat the very end of the command. So :.t0 will succesfully copy the current line to the top of the file. Because of this quirk, you can use -0 instead of . to reference the current line at the end of a copy command (e.g., :123t-0).
To Reproduce
Steps to reproduce the behavior:
Enable Neovim (vim.enableNeovim: true).
Open a file with some lines in it. Move to (e.g.) the third line.
Type :1copy. (or :1co., or :1t.; they are equivalent AFAIK).
See "E488: Trailing characters" error.
Expected behavior
The first line should be copied to the position after the current line.
Environment (please complete the following information):
Extension (VsCodeVim) version: v1.21.7
VSCode version: 1.60.0
OS: 11.5.2 (also tested on Ubuntu 21.04)
The text was updated successfully, but these errors were encountered:
patbl
changed the title
Ex "copy" command with . (current line) stopped working
Ex "copy" command with . (current line), - (previous line), or + (next line) at end of command stopped working
Sep 4, 2021
patbl
changed the title
Ex "copy" command with . (current line), - (previous line), or + (next line) at end of command stopped working
Ex "copy" command with ., -, or + (current, previous, or next line) at end of command stopped working
Sep 4, 2021
Describe the bug
In ex commands, you can use
.
to refer to the current line. So:5,.d
means "delete everything between the 5th and current line (inclusive)." The dot doesn't work with thecopy
Ex command. It does, however, work with other commands, such asmove
anddelete
.Also,
.
,-
, and+
work as long as they don't appear tat the very end of the command. So:.t0
will succesfully copy the current line to the top of the file. Because of this quirk, you can use-0
instead of.
to reference the current line at the end of acopy
command (e.g.,:123t-0
).To Reproduce
Steps to reproduce the behavior:
vim.enableNeovim: true
).:1copy.
(or:1co.
, or:1t.
; they are equivalent AFAIK).Expected behavior
The first line should be copied to the position after the current line.
Environment (please complete the following information):
The text was updated successfully, but these errors were encountered: