A very common operation that I want to do is work out how a file got to the state it is, who is responsible for that ghastly piece of code.
However I can find no way of doing this in SourceTree (Windows version 188.8.131.52).
Since it has no normal tree view of the working copy I can't just find the file, right click and say "blame" like I would expect.
I've naively tried using the search tab and typing in the source name and selecting the "File Changes" from the search type drop down. However it just sits forever thinking.
Is there a way to do what I want?
By "If you can find it", presumably you mean "if you can find the file somewhere in the user interface to have something to click on". And that's the basic issue. I know where the file is in my source tree, I just can't get an object anywhere in the UI to represent it, to have a context menu to select "blame selected" on. The only way I know is if I can find some commit under which it has changed, but almost by definition I don't know that in this scenario.
I'm not even sure "search file changes" is what I want. I've just tried on another repository cloned off an open source project and what I get in "Search: File changes" is, well I don't know what to be honest. It's a bunch of descriptions, dates, authors and commit hashes, but it's unclear to what files they relate. If I pick one, the files under the commit details aren't anything related to the term I put in the search dialog. Ahh. The diff to one of the files does contain the text I searched for. OK clever, but actually not at all what I'm after. Can't actually think of a scenario in which I'd want that. Now a "search the names of files in the working copy" would be a useful feature.
Perhaps our repository is just too big for the search? It's not small, but it's hardly enormous.
This is such a basic requirement to me that I'm surprised it's so hard. There must be a way of doing a blame or a log on an arbitrary file. I can do it simply using the git-gui windows integration, but I was hoping for a single gui, rather than using git-gui for some things and SourceTree (or something else) for others.
The problem is the default view is only for modified files - however *you can change the view to show all files*. Its just as bit cludgy.
First, change the view to "File Status View" (on OSX, View --> File Status View)
Then, there is a selection menu on the actual app. Hard to describe, but its a menu bar beneath the icons menu bar, grouped with a few others:
Flat View | Tree View || Column View | *Show ... *
The "Show" selection can be changed to "Show All" - when I set mine, it was on "Show Modified"
Would probaly make more sense to have that option in the View menu proper.
Supported Platforms macOS Sourcetree has a lot to offer and, like many developer tools, finding and using it all can be a challenge, especially for a new user. Everyone might not love ...
Connect with like-minded Atlassian users at free events near you!Find a group
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no AUG chapters near you at the moment.Start an AUG
We're bringing product updates and pro tips on teamwork to ten cities around the world.Save your spot