Function: ibuffer-do-shell-command-pipe
ibuffer-do-shell-command-pipe is an autoloaded, interactive and
byte-compiled function defined in ibuf-ext.el.gz.
Signature
(ibuffer-do-shell-command-pipe COMMAND)
Documentation
Pipe the contents of each marked buffer to shell command COMMAND.
Key Bindings
Source Code
;; Defined in /usr/src/emacs/lisp/ibuf-ext.el.gz
;;;###autoload (autoload 'ibuffer-do-shell-command-pipe "ibuf-ext")
(define-ibuffer-op shell-command-pipe (command)
"Pipe the contents of each marked buffer to shell command COMMAND."
(:interactive "sPipe to shell command: "
:opstring "Shell command executed on"
:before (ibuffer--maybe-erase-shell-cmd-output)
:modifier-p nil)
(let ((out-buf (get-buffer-create shell-command-buffer-name)))
(with-current-buffer out-buf (goto-char (point-max)))
(call-shell-region (point-min) (point-max)
command nil out-buf)))