How can I reload .emacs after changing it?

前端 未结 18 867
余生分开走
余生分开走 2020-12-12 08:51

How can I get Emacs to reload all my definitions that I have updated in .emacs without restarting Emacs?

18条回答
  •  不思量自难忘°
    2020-12-12 09:19

    You can set key-binding for emacs like this

    ;; reload emacs configuration
    (defun reload-init-file ()
      (interactive)
      (load-file "~/.emacs"))
    
    (global-set-key (kbd "C-c r") 'reload-init-file) 
    

    Hope this will help!

提交回复
热议问题