Live data from Hacker News

Setting up Sublime Text 2

blog.alexmaccaw.com

1–10 of 141 posts

Re: Setting up Sublime Text 2

#3

You shouldn't set "trim_trailing_white_space_on_save": true unless you work alone, otherwise you're going to have random whitespace changes polluting your diffs.

Our coding guidelines at Stripe specify that whitespace is to be stripped. It works if everyone does it.

On the occasion where whitespace does pollute the diff, GitHub has a convenient feature where you can append '?w=1' to any diff URL and whitespace changes will be omitted.

Re: Setting up Sublime Text 2

#4
post #3

You shouldn't set "trim_trailing_white_space_on_save": true unless you work alone, otherwise you're going to have random whitespace changes polluting your diffs.

Our coding guidelines at Stripe specify that whitespace is to be stripped. It works if everyone does it. On the occasion where whitespace does pollute the diff, GitHub has a convenient feature where you can append '?w=1' to any diff URL and whitespace changes will be omitted.

The number of pull requests I get where the diffs are completely unreadable because someone has this feature enabled is insane. On certain whitespace dependent languages (I'm looking at you Python) simply supressing the whitespace in the diff is not an option.

What are the arguments for having whitespace removal as a coding standard?

Re: Setting up Sublime Text 2

#7
A few more Sublime Text plugins worth checking out:

AdvancedNewFile -- easy file/directory creation

Alignment -- shortcut for instant alignment

Emmet -- essential for HTML/CSS

GitGutter -- see diff marks in gutter

Origami -- additional shortcuts for split panes

VintageEx -- emulation of Vim's Ex-mode

The Vim emulation isn't one-to-one, but it's pretty good with Vintage mode enabled and the VintageEx plugin installed.

Post reply on HN