Search code examples
objective-cxcodegitversion-controlsourcetree

Source tree crashes with many uncommitted changes on Xcode (possibly other IDEs)


Problem: I had a considerable amount of changes pending to be committed. When I tried to commit some of by blocks (a block at a time) eventually, source tree stopped working (the loading spinners were shown and the user interface was not responding). I’ve tried to fix this issue by closing the application entirely, that didn’t work, source tree was not responding after a few seconds of re-launching the application.


Solution

  • Beware, you will lose your uncommitted changes so backup your important changes , or commit them using your IDE if supported.

    • Close source tree: cmd+alt+esc and kill the application.
    • Go to Xcode - Source control - Discard all changes
    • After that, go to Source control, under working copies, put your mouse over the current branch, a menu will be shown, select Switch to Branch and select other of your branches to force Source tree to "move on”.
    • Launch Sourcetree, it worked for me on the second attempt.
    • If when launching Sourcetree there still uncommitted changes, then force quit Sourcetree and Discard all changes from Xcode again. Relaunch Sourcetree.

    Worked for me.

    Hope it helps someone.