Subject: bug#14637: recent viper-mode regression

From: Jim Meyering <[email-masked]>
Date: Mon, 17 Jun 2013 00:59:55 +0200

Hello,
I periodically use built-from-git emacs and noticed that in the
last couple of weeks a common command in viper-mode, "!Ggrep ..."
had begun to malfunction.  Normally, !G<cmd> runs CMD on the contents
of the buffer (from the line with point to EOF) and replaces those
lines with the output of the command.

Now, however, it merely appends the result, instead of replacing the
source lines.

E.g., if you run this,

  seq 10 > k; emacs -q -nw -f viper-mode k

then type "!Ggrep 3", you'll end up with this in your buffer:
  1
  2
  3
  4
  5
  6
  7
  8
  9
  10
  3

Instead, the buffer should (and used to) contain this single line:

  3