[ESS] history button in ESS

Barry Rowlingson B.Rowlingson at lancaster.ac.uk
Wed Jan 4 12:58:02 CET 2006


Stephen Eglen wrote:

> Try M-p (the meta key and p at the same time, or press Escape and then
> p). M-p / M-n will move you through the history, and will do the same
> thing e.g. in M-x shell 


If you want the arrow keys to recall commands, then add this bit of lisp 
to either your .emacs or site-start.el files:

(eval-after-load
  "comint"
  '(progn
     (define-key comint-mode-map [up] 
'comint-previous-matching-input-from-input
)
     (define-key comint-mode-map [down] 
'comint-next-matching-input-from-input)
     (define-key comint-mode-map [?\C-a]  'comint-bol)
     (define-key comint-mode-map [?\C-c ?\C-a] 'beginning-of-line)))

  - actually I'm not sure what the last two bits do exactly, but the 
first two 'define-key' things do the command recall thing.

Barry




More information about the ESS-help mailing list