Prevent pdb file registration in Visual Studio 2012 with TFS 2010

We recently switched to Visual Studio 2012 from Visual Studio 2010. We are still using TFS 2010, and we are using closed validation. Since we started using Visual Studio 2012, when checking in VS, pdb files from the output folder of one of our projects are automatically included in the changeset. Of course, we can manually exclude them from registration, but this can lead to errors, because if someone forgets to exclude these files, all assemblies after verification will fail.

I do not want pdb files to be checked, I just want to set the default value as excluded. In fact, in Visual Studio 2010, they were not automatically added to the original control as a change.

The weirdest part is that if you go to the command explorer and "Add items to a folder" by default, all pdb files are excluded (which is the correct behavior), so I don’t understand why Visual Studio adds pdb files to the output folder in the set changes.

UPDATE After trying all attempts, there is still a problem. I already deleted the bin folder from TFS, but Visual Studio 2012 continues to include the DLLs in the output folder in the changeset. In the meantime, we upgraded to TFS 2012, but the problem remains.

+4
source share
2 answers

You can add the tfs.tfignore file, which you can add * .pdb files to automatically exclude. You can add this file to a folder or project level.

Configure which files are ignored during version control

Another solution:

Assuming you have the necessary permissions,

  • Team Explorer, right-click the name of the root server, hover over the settings of Team Foundation Server,
  • Select Source Control File Types. A window opens listing all file types that TFS recognizes from the box.
  • Select the types of files that you want to exclude from the original control, and click the Delete button. Note. This applies to all projects on the TFS server.
+3
source

In general, you should not check the output folder at all. If you did not specify in the output folder, you will not check .pdb files.

0
source

Source: https://habr.com/ru/post/1482548/


All Articles