M-x term とかだと引数付けられないので。 (require 'term nil t) (defvar term-shell-command-history nil "History for `term-shell-command'") (defun term-shell-command (command &optional buffer-or-name) "Run COMMAND in terminal emulator. If BUFFER-OR-NAME is given, use this buffer. In this case, old process in the buffer is destroyed. Otherwise, new buffer is generated automatically from COMMAND." (interactive (list