avoiding eclipse “changed on file system” dialog?

前端 未结 2 1760
青春惊慌失措
青春惊慌失措 2021-02-05 03:25

Is there a preference or tweak that will stop Eclipse from putting up a dialog \"This file has been changed on the file system.\" when I switch to Eclipse from another editor?

2条回答
  •  死守一世寂寞
    2021-02-05 03:53

    This works for me using Indigo Service Release 1, Build id: 20110916-0149, with Preferences->General->Workspace->"Refresh Using Native Hooks or Polling" and "Refresh on Access" checked.

    @Piotr Dobrogost, only one of these options is needed to get rid of the dialog prompt, however it depends on what behavior you want. They do different things, but each on its own prevents the dialog. With "Refresh Using Native Hooks or Polling", the file will automatically update when the file changes without user intervention. With "Refresh on Access", the file updates only when the context changes to the editor containing the changing file. For my purposes (watching script output change), I find "Refresh Using Native Hooks or Polling" by itself the most useful.

    Also, this may seem obvious, but note that this only works for files in the eclipse workspace.

提交回复
热议问题