Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is there any way to delete or alter file history changes in a Team Foundation Studio repository?

Tags:

tfs

A team member's username/password was inadvertently checked in to a file in source control. While the person will likely have to change their username and password anyway, is there any way to delete this history of the file from TFS?

Ideally, we could just blank out the password within the history. I found where the data is stored in SQL, but the data is hashed, so I can't just edit it directly (I don't think).

Thank you.

like image 442
Jeff Davis Avatar asked Jan 23 '12 18:01

Jeff Davis


1 Answers

Generally speaking, history is mostly immutable, however you can destroy items that were errantly checked in using the tf destroy command. For example:

tf destroy $/Project/Folder/file.txt

will permanently delete all references to that file in history.

(To clarify what I mean by "mostly immutable": aside from being able to destroy historic items, you cannot modify version control history, that is the changes that comprise a changeset. However, some version control metadata can be changed, including changeset comments, work item associations, and check-in notes.)

like image 175
Edward Thomson Avatar answered Sep 18 '22 11:09

Edward Thomson