SED - Standard key bindings quick reference

SED  -  Standard Key Bindings Quick Reference

Top  Previous  Next

 

Simple Cursor Movements        "All the way" movements

 

           Ctrl-P (previous)                       Esc-<

             ^                                       ^

             |                                       |

             |                                       |

             |                                       |

Ctrl-B  <---- . ----> Ctrl-F            Ctrl-A  <---- . ----> Ctrl-E

(backwards)   |       (forwards)                      |       (end)

             |                                       |

             |                                       |

             v                                       v

           Ctrl-N (next)                           Esc->

 

 

Delete char

Ctrl-D

 

Backspace

Backspace key

 

Delete line

Ctrl-K

Alternates between deleting text and newline

Forward one screen

Ctrl-V

 

Backward one screen

Esc-V

 

 

 

 

 

 

 

Other Important Keys  

Cancel

Ctrl-G

Terminates partly entered codes

Save changes

Ctrl-X S

 

Close editor

Ctrl-X C

 

 

 

 

 

 

 

Searching and Replacing

Forward search

Esc-S

Prompts for search string, defaulting to last

Reverse search

Esc-R

Prompts for search string, defaulting to last

Replace

Ctrl-X R

Prompts for search string and replacement

Query replace

Ctrl-X Q

Like Replace but queries each change

View

Ctrl-X V

View all lines containing specified text

 

 

 

 

 

 

Other Movements

Forward word

Esc-F

 

Backward word

Esc-B

 

 

 

 

 

 

 

Cut and Paste

Set mark

Esc-.

Marks current cursor position

Copy region

Esc-W

Saves a copy of the text between the cursor and the mark

Delete region

Ctrl-W

Deletes the text between the cursor and the mark, saving it

Paste

Ctrl-Y

Inserts text saved by Esc-W, Ctrl-W or Ctrl-K