gitvisual-studio-2015resharper

VS2015: Quick way to switch from diff to original file


Recently we switched to Git and use the integrated Git environment of Visual Studio 2015.

If you view changes to a file via the team explorer, it starts comparing the modified one with the original version. When you're viewing changes in history, you can't modify the file in the diff of course. However, we don't really have a good way of switching to the original file. We discovered setting a breakpoint works sometimes... But mostly we have to close the file opened for comparison and then navigate to the original file. I really have the feeling I'm overlooking something.

So, is there a quick way to switch from the file diff of Visual Studio to the original file being diffed?

PS: I don't know if it's relevant but we're using Resharper.

PPS: I'm using Jetbrains Rider for a few years now where I can just press F4 and it opens the original file and places the cursor at the right place as well.


Solution

  • You can use Shift + Alt + L to navigate to the file in solution explorer then hit enter to open the file you were diffing.