开发者

Hotkey for TFS checkin

开发者 https://www.devze.com 2023-01-21 16:40 出处:网络
I have just started using TFS and have some questions about hotkeys. It is really uncomfortable to select projects, solutions and files in Solution Explorer.

I have just started using TFS and have some questions about hotkeys. It is really uncomfortable to select projects, solutions and files in Solution Explorer.

I want to assign hotkeys to just 2 operations:

  • Solution-wide checkin
  • Solution-wide get latest version

But I cant find these开发者_运维百科 in the list of available operations in Visual Studio Keyboard Settings. Can someone help me with the names of operations if they are available?


Actually, there are a whole bunch of commands available under Tools|Options|Environment|Keyboard, to which you can assign shortcuts. Some of them are:

  • File.TfsCheckIn
  • File.TfsCheckInSilent
  • TfsCheckInDynamicSilent
  • ...

I can't tell you exactly what is what and what is best for you to use. I guess there's some documentation about this out there - at least I hope so ;-)...

HTH!
Thomas


If you can't live with selecting the solution node in the solution explorer and use a hotkey for File.TfsCheckIn, I guess that your only options is to use a macro like this and assign a hotkey for that:

Sub CheckInSolution()
    DTE.Windows.Item(Constants.vsWindowKindSolutionExplorer).Activate()

    Dim fi As System.IO.FileInfo = New System.IO.FileInfo(DTE.Solution.FullName)
    Dim name As String = fi.Name.Substring(0, fi.Name.Length - fi.Extension.Length)

    DTE.ActiveWindow.Object.GetItem(name).Select(vsUISelectionType.vsUISelectionTypeSelect)
    DTE.ExecuteCommand("ClassViewContextMenus.ClassViewProject.TfsContextCheckIn")
End Sub


for checkin :

CTRL + \ , CTRL + M - Switch to Team Explorer
Alt + I - commit changes.

don't forget the comment!


Not feasible, unless you only run very little of TFS 2010.

TFS 2010 when properly used requires a lot more than just checking in - including attaching your checkin to the work items that it is realted to. A hotkey would make this impossible. In TFS you do not check in THAT often, only to complete items of work (or if they are very long sometimes on the site). I do about 4-5 checking per day and they CAN take time (integration, validation, documentation), so a hotkey would bring me nothing.

0

精彩评论

暂无评论...
验证码 换一张
取 消