How to find out who is logged in as another user (using / author)

In TFS2010, you can check on behalf of another user (provided that he has permission to do this):

> tf.exe checkin (...) /author:OtherUser 

The check history shows OtherUser as the user who completed the check:

 > tf history (...) /noprompt Changeset User Date Comment --------- ----------------- ---------- ----------- 1234 OtherUser (...) 

I found a blog post that said: "Both your username and the other user are written to the changeset data so you can always determine who checked for the changes." I assume it is written to Changeset .Commiter vs ChangeSet.Owner, but tf history or tf changeset does not display this.

Is there any interface / tool that displays this information?

[edit] Note: It seems that Commiter can mean two different things:

  • A user who logged in as OtherUser using tf checkin /author .
  • The user who runs the gated checkin (machine account or build user).

In case you did a tf checkin /author in a gated check, then a value of 1 wins.

+4
source share
1 answer

You are right, there are two different users.

  • Changeset.Committer - The user who actually signed up (that is, the authenticated user on the server)
  • Changeset.Owner - the user whose registration was performed on behalf of (i.e. specified as /author:OtherUser )

The Visual Studio user interface will not show you two different users. It will show you only the owner / author. (This makes sense, as it rarely happens that the committer will be different)

If you want to see both users, you can use the following command line with the / noprompt switch to force console output:

 C:\code>tf changeset 1234 /noprompt Changeset: 1234 User: ChangesetOwnerOrAuthorUser Checked in by: ChangesetCommitterUser Date: Friday, 1 February 2013 12:00:00 PM Comment: Items: edit $/project/test/test.txt 
+2
source

All Articles