The vimsed script makes vim behave kind of like sed. Syntax: vimsed "<vim normal-mode keystrokes>" vimsed will "pipe" stdin to stdout, modifying it first by running the keystrokes. Note/Warning: Uses temporary files temp, temp.vim and temp2 in the ~ directory. Example: (type ctrl-v enter to get the ^M, it stands for a carriage return) $ vimsed ":s/e/i/g^M" (user input:) hello hello (Ctrl-D to terminate user input) (vimsed output:) hillo hello