Team System Developer Center >
Visual Studio Team System Forums
>
Team Foundation Server – Power Tools & Add-ons
>
tfpt rollback not working
tfpt rollback not working
- Hello,
I'm trying to use the TFS Power Toys tool to rollback some changesets to see if a bug was occurring before they were checked in.
I have a couple workspaces, one that has my changes and another one that's supposed to be identical to what's checked in. In order to make sure that my workspace is identical to what's checked into tfs I ran:
tfpt scorch /noprompt
I then ran a batch file that calls a dozen or so commands like:
tfpt rollback/changeset:1234
tfpt rollback/changeset:1235
tfpt rollback/changeset:1236
etc.
However, each one of them is returning a:
Cannot proceed because you have pending changes in your workspace. You must move to a shelveset, undo, or check in all p
ending changes before reverting a changeset.
I wondered if my batch file itself was making tfs "think" that I had changes in my workspace, so I moved it outside my workspace and added a cd \myworkspaceroot command at the top of it.
So my batch file now looks like:
cd \myworkspaceroot
tfpt scorch /noprompt
tfpt uu
tfpt rollback/changeset:1234
tfpt rollback/changeset:1235
tfpt rollback/changeset:1236
etc.
The tfpt scorch command in the above batch file is returning:
Walking C:\myworkspaceroot\soft1 ... found 2
Walking C:\myworkspaceroot\soft2 ... found 7
Checking the status of 5 individual items... done
Checking the status of 2 directories, recursively... done
No inconsistencies found.
The tfpt uu returns:
Bringing the workspace up to the latest version...
Getting the list of pending changes for your workspace...
Building the list of redundant changes...
There are no redundant pending changes.
all of the tfpt rollback /changeset:mychangesetnumber look like:
Cannot proceed because you have pending changes in your workspace. You must move to a shelveset, undo, or check in all p
ending changes before reverting a changeset.
Any idea why tfpt rollback is failing when run immediately after a scorch and a tfpt uu?
-Eric
Answers
- Hi Eric,
Scorch Command:
This command scans your local disk for items that are not in source control. These items are then deleted from your local disk, Items with pending changes are exempted.
UU (Undo Unchanged) Command:
Use the UU command to undo unchanged filed, including adds,edits and deletes.
If a file is check-out and modified, Scorch will ignore it because it has pending changes and UU will ignore it because it is changed. So after these 2 commands, there are still files with pending changes and rollback command failed.
You can just use tf get command to get last or specified changeset.
Best Regards,
Ruiz
Please remember to click “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread. Sincerely, Ruiz Yi- Marked As Answer byRuiz YiModeratorFriday, October 09, 2009 6:14 AM
All Replies
- Hi Eric,
Scorch Command:
This command scans your local disk for items that are not in source control. These items are then deleted from your local disk, Items with pending changes are exempted.
UU (Undo Unchanged) Command:
Use the UU command to undo unchanged filed, including adds,edits and deletes.
If a file is check-out and modified, Scorch will ignore it because it has pending changes and UU will ignore it because it is changed. So after these 2 commands, there are still files with pending changes and rollback command failed.
You can just use tf get command to get last or specified changeset.
Best Regards,
Ruiz
Please remember to click “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread. Sincerely, Ruiz Yi- Marked As Answer byRuiz YiModeratorFriday, October 09, 2009 6:14 AM
Ruiz,
I'm trying to get a "snapshot" of the code that was promoted to an environment.
If I get the latest I've got several changesets in there I don't want. I don't see how I can get rid of them. I don't understand why it thinks I have pending changes. This workspace is one in which I don't do any development in, it's just supposed to be a snapshot of what's checked in tfs.
-Eric- Hi Eric,
TFPT rollback command will check all workspaces in local client, so maybe there is pending changes in other workspace.
In additional, You can get a specified changeset instead of last.
Best Regards,
Ruiz
Please remember to click “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread. Sincerely, Ruiz Yi


