amperser / proselint

A linter for prose.
http://proselint.com
BSD 3-Clause "New" or "Revised" License
4.36k stars 179 forks source link

Exclude code #342

Open plaindocs opened 8 years ago

plaindocs commented 8 years ago

I'm interested in running this on technical documentation, but for it to be meaningful you'd have to exclude any code in backticks or code blocks, and I can't see an easy way to do that.

alexyorke commented 8 years ago

You could run this find-replace regex ([^`]+) (and put one back tick before and after it, then /g since markdown is eating my ticks.) That regex would just remove all code blocks, after which you can just run it through proselint.

plaindocs commented 8 years ago

Heh, that would work, yeah.

alexyorke commented 8 years ago

It is a bit of a messy workaround though, and it would be very nice to have proselint have this as a feature though since *.md files are supported.

plaindocs commented 8 years ago

It is hacky yes (and would ruin any line number info you get)