Hacker News

vcoppola
Show HN: Holywell – The missing SQL formatter for sqlstyle.guide github.com

For nearly a decade, I've wanted a SQL formatter that followed Simon Holywell's style guide (https://sqlstyle.guide). If you're unfamiliar with it, one of its key (and most controversial) features is “river alignment” of keywords. I couldn’t find an existing formatter that implemented it, so I made Holywell.

Try it in the browser: https://holywell.sh Repo: https://github.com/vinsidious/holywell

The site has a bunch of scrollable examples so you can quickly see what the formatted SQL looks like.

Dialect support is pretty basic right now (I’m mostly a Postgres user), but I’d love requests / failing examples for other dialects. Also, PRs are very welcome.

Disclaimer: not endorsed by Simon Holywell. I tried to be faithful to the guide (and where the guide is ambiguous, I had to interpret). Also: I’m not claiming this style is “best” — just that it’s the one I’ve wanted for a long time.

Please share your thoughts and let me know where it falls short!


hn-front (c) 2024 voximity
source