Last Updated: February 25, 2016
·
1.746K
· jshakes

Pretty diff output with Sublime

Reading the output of diffs in the command line can be tricky, so why not make use of Sublime Text's built in syntax highlighting to view your changes.

Just save the output of the diff to a file using

diff path/to/first/file path/to/second/file > output.txt

(Or, if you're using git)

git path/to/file > output.txt

And open it with ST2. You'll get a nice, readable version of your file.

Sublime preview

1 Response
Add your response

You don't have to save output to the file... This will be just fine

diff path/to/first/file path/to/second/file | subl

or with TextMate

diff path/to/first/file path/to/second/file | mate
over 1 year ago ·