I found a whole bunch of green ^\
characters in the file I have open in vim...
Any idea what control character they are?
And how would I search for them in grep?
Vi and Vim Stack Exchange is a question and answer site for people using the vi and Vim families of text editors. It only takes a minute to sign up.
Sign up to join this communityI found a whole bunch of green ^\
characters in the file I have open in vim...
Any idea what control character they are?
And how would I search for them in grep?
If it is indeed a single character, it’s likely to be <C-\>
. You can use ga
to get the ascii, octal, etc., versions.
For grep(1)
, most shells (my bash, at least) will let you input literals with <C-v>
much like vim.
File Separator, code point 28, or 0x1C, originally used to delimit data structures.
If you cannot type it with Ctrl+\
, you can use alt codes if you have a number pad on your keyboard. Type Alt+28
and you should get something that looks like this: ∟ You must use your number pad, the keys above the letter keys will not work. If your keyboard doesn't have a number pad, you can copy-paste the character from here: ∟
Alt+28
doesn't do anything except select the menus at the top when I try it, what kind of window are you typing in?
– leeand00
Aug 30 '19 at 13:46
28
, if you're on Linux or Mac, try opening your browser and going to something like google docs (or this comment thread), because browsers rarely have Alt-Keys to prevent from interfering with webpage Access-Keys (an almost unused technology, but uninterfered with anyways) If that lets you type it in, you can probably copy-paste from there.
– Ben
Aug 30 '19 at 15:17