Eclipse TFS plugin not detecting changes

2019-07-20 16:50发布

问题:

I am using Eclipse Version: Neon.3 Release (4.6.3), and have installed TFS plugin in it.

When I am making any changes to the code, the changed files not show up in Included Changes in TFVC Pending Changes Tab, all the changed files show up there only after restart of the eclipse or manually clicking on Action -> Detect Local Changes.

Anybody have solution to this problem, so that I dont have to restart eclipse or or manually clicking on Action -> Detect Local Changes and it detects it automatically.

回答1:

First, please double check whether you are using server workspaces or local workspaces.

  • In a server workspace, TFS requires that you inform the server for every change - to check out a file, rename, delete, etc. This allows TFS to avoid scanning your disk for changes, which is beneficial for large repositories. If you want to force a disk scan with Team Explorer Everywhere, because you may have made some changes outside of Eclipse, you can go to the Actions menu and select Detect Local Changes.
  • In a local workspace, TFS will examine your disk for changes every time you look at the pending change status. So all you have to do is run tf status or click refresh in the Pending Changes View to see changes made to files outside of Eclipse.

According to your description, seems you are using serverworkspaces. If so suggest you switch to a Local workspace, in which case TFS will store a copy of your file in a hidden folder, so that it always knows what your workspace version looked like when TFS served it to you.

As how to judge you are working on server workspace or local workspace and edit workspaces, follow below steps:

  1. In Project Explorer or Package Explorer, right-click an Eclipse project that is under version control, point to Team, and click Manage Workspaces.

  1. The Workspaces dialog box appears. It shows you the list of your Team Foundation Server workspaces.
  2. Then select the one you want to convert, click Edit; the Edit Workspace dialog box appears just as below screenshot:

Note: Local workspaces are only supported for Team Foundation Server 2012 and above.