Sublime as default editor and Diff tool for MAC Git - Git Commands


Diff Tool

You can use you Console or edit the config file directly. Either will work.


Run this:

git config --global diff.tool subl                   
("l" is and lowercase L)

Then run this:

git config --global difftool.subl.cmd "subl --wait --diff $LOCAL $REMOTE"


Add to the Config file in your Git directory.

    tool = subl
[difftool "subl"]
    cmd = "subl --wait --diff  $LOCAL $REMOTE"


Default editor

git config --global core.editor "/Applications/Sublime" /usr/local/bin/subl