Open OneCyrus opened 9 months ago
We're definitely interested in this, but it's a serious endeavor and we'll need to dedicate some time to the design :)
@OneCyrus It looks like Sleek may be up your alley for the time being, at least as far as formatting goes. It was easier to set up than sqlfmt.
and https://github.com/pre-commit/mirrors-prettier
Archived
prettier made some changes that breaks plugins entirely
There is now a Rust rewrite of sqlfluff named sqruff
.
Hey 👋, Ben here from Quary, I just saw this! Yep, we would be happy to integrate https://github.com/quarylabs/sqruff in a way that makes sense, feels like there could be a nice way of doing this!
If this is implemented would that make ruff format SQL within the strings, or this feature only asks to format SQL files separately?
Slightly unrelated, but what's the recommended way to write python code with raw SQL?
If this is implemented would that make ruff format SQL within the strings, or this feature only asks to format SQL files separately?
What's the recommended way to write python code with raw SQL?
@benfdking I'd also be pretty intrigued on what y'all's intended outcome for this. (I really enjoy sqruff by the way, I can completely understand sqruff being a completely separate tool.)
I also enjoy sqruff due to its speed, but there's still quite a few things that feel not implemented. It would be good to get more hands on deck. I've been working on quite a few fixes as I get it integrated into my project I'll be submitting a pr for, but would still be great to have it built into ruff.
i think there's a huge overlapping userbase of python users who work in the data engineering space. the current lanscape of good tooling to format and lint sql files is not great and something like ruff for those scenarios could be huge.
basically ruff to replace sqlfmt and sqlfluff would be awesome.
https://sqlfluff.com/ https://sqlfmt.com/