How can I get Emacs to revert all unchanged buffers when switching branches in git?

前端 未结 3 784
面向向阳花
面向向阳花 2020-12-23 09:13

Often, when I switch branches in git, if the files are open in emacs, then emacs asks if I want to revert them (as it thinks they\'ve changed on disk) even though the conten

3条回答
  •  自闭症患者
    2020-12-23 09:51

    Perhaps you'd like the global auto-revert mode. Try running global-auto-revert-mode and if you like it you can add (global-auto-revert-mode) to your ~/.emacs file.

提交回复
热议问题