dim – visualize your Git diff in TextMate

I use git as my primary version control system and one nice alias that I have in my ~/.bash_profile is “dim”. When I type in “dim”, I see my Git diff within TextMate which makes it easy to see what I’m about to commit.

Here’s the entire source:
alias dim="git diff | mate"

It should automatically pick the “Diff” language for you, but if not, then just pick it from the chooser at the bottom of the window to get the nice highlighting where deleted lines are in red, added lines are in green and markers are in blue.

This entry was posted in Programming and tagged , , , . Bookmark the permalink.

3 Responses to dim – visualize your Git diff in TextMate

  1. Jose Lobato says:

    I use Changes for git diff.
    In the Changes web site the configuration needed can be found. You can also find full explanation on the cocoa gurus web page .

  2. Paul Barry says:

    You should use GitX. You can see the files that have changed, easily navigate between files to see each diff, easily discard changes you don’t want, construct your commit message and even amend the previous commit. It’s an awesome tool:

    http://gitx.frim.nl

  3. Darren says:

    Or gitnub, cause it integrates with github if you want and it’s a nice mac os x style interface like gitx.

    http://github.com/Caged/gitnub/