How to ignore files according to their extension in TFS?

Asked

Viewed 289 times

3

In git you can use the file . gitignore to ignore some file extensions, but would like to know if this can also be done in Team Foundation Service or if there is something similar to ignore files with certain extensions.

1 answer

3


In the local Workspace you will have the file . tfignore (TFS 2012, 2013, 2015 and higher)

In the local Workspace, you can use . tfignore (which is equivalent to Git . gitignore)

.tfignore example:

######################################
# Ignore .cpp files in the ProjA sub-folder and all its subfolders
ProjA\*.cpp
# 
# Ignore .txt files in this folder 
\*.txt
#
# Ignore .xml files in this folder and all its sub-folders
*.xml
#
# Ignore all files in the Temp sub-folder
\Temp
#
# Do not ignore .dll files in this folder nor in any of its sub-folders
!*.dll

Remembering that . tfignore is valid for new files.

  • I already have a version control project, so I created the file. tfignore with the extensions to be deleted and gave check-in, but the files with the respective extensions remain in the list of included changes.

  • and in the list of changes if you give a right button ignore works for you?

  • 1

    anything look https://stackoverflow.com/questions/36768954/visual-studio-2015-tfs-tfignore-file may be the wrong file format

  • Well, what happens is that . tfignore is only valid for files that are not yet in version control, so I wasn’t getting it. Thanks for the link, helped a lot !

  • @Carlinhos added the comment in the reply, if it helped you mark as solved.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.