Best Answer: How Do I Find Control M Characters in Unix?
Contents

Note: Remember how to type control M characters in UNIX, just hold the control key and then press v and m to get the control-m character.

What is Ctrl-M character in Unix?

It is known as carriage return. If you’re using vim you can enter insert mode and type CTRL – v CTRL – m . That ^M is the keyboard equivalent to r. Inserting 0x0D in a hex editor will do the task.

How do I find M in vi?

In order to be able to enter it, you need to escape it, and you can use Ctrl + V for that purpose. (See :help c_CTRL-V for more details.) So in order to search for it, you can start search with / , then press Ctrl + V , then Ctrl + M . You’ll see the ^M notation.

Robert Thorne

Robert Thorne

Automotive & Future Transportation Editor

Robert Thorne covers electric vehicle innovations, autonomous driving systems, global mobility trends, and automotive engineering developments.

Share this article
Twitter Facebook Pinterest