How can I to remap incremental search (C-s) to C-f in Emacs?
I try to do (global-set-key (kbd \"C-f\") \'isearch-forward)
but the
(define-key isearch-mode-map "\C-f" 'isearch-repeat-forward)
isearch-repeat-forward
is defined in the isearch-mode-map
To resolve your problem do the following :
(global-set-key (kbd "C-f") 'isearch-forward)
(add-hook 'isearch-mode-hook
(lambda ()
(define-key isearch-mode-map (kbd "C-f") 'isearch-repeat-forward)
)
)
EDIT: actually, you don't need to add a hook. The accepted answer by Ross Patterson is correct.