By josh / May 2, 2013

How to view file changes in a git-style diff

It’s late in the day, and the website is coughing up 500 errors. You hate to do it, but there’s no choice: You’re going to have to edit a file on your production server.

You pop it open, make a few changes. Your fingers reach for the save shortcut… And that queasy feeling hits your gut: What if I made a mistake?

But hold on to that pink sombrero—Sublime has a little-known feature that you can use when you want to be extra sure before you save your changes.

Just right-click in the editing pane and select Show Unsaved Changes, and you’ll get a nice git-style diff that you can review one last time.

Now you’re a hero.

Plugin of the Week

Sublime Text 2 Stack Overflow allows you to query Stack Overflow from a Command Palette-style popup, or search by highlighting a snippet of code.

How-To & Interesting Articles

How to Add SASS Support to Sublime Text

Distraction Free Mode, Color Picker and Placeholders

Have you seen Emmet yet? It will blow your mind.

For more great Sublime tips and tricks, go here:

http://sublimetexttips.com/newsletter

About the author

josh

Click here to add a comment

Leave a comment: