How do I delete all occurrences of \\\\
from cursor position to the end of file?
What I tried:
:%s/\\\\//g
deletes single \\
and in all the file.
:g#\\\\#$d
does not really work.
Try :.,$s/\\\\\\\\//g
\\
will escape the second \\
, so you need to use 4 to get 2 literal backslashes. %
in :%s
is shorthand for 1,$
(or the first line, to the end of the file). If we change this to .,$
, our substitution will run from the current position to the end of the file.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.