Open benbrittain opened 1 year ago
Buildifier works pretty well on BUCK files. find . -name BUCK | xargs -n1 buildifier -path=BUILD
We're using buildifier
for formatting the BUCK files already, it works fine. That being said, having an obvious single point of entry is always a nice. Not a big deal, but potentially nice quality of life improvement.
The plan would be to add a formatter to the https://github.com/facebookexperimental/starlark-rust library, and then expose it through buck2 starlark fmt
or similar. Vaguely something we'd like to do, but someone writing a formatter is the first step.
I'm currently using
buildifier
to do formatting for our project. That being said, if we do wind up actually migrating frombazel
tobuck2
, it would be nice if we could unify our tooling entirely. Are there any plans to leverage the starlark parser withinbuck2
to provide a formatting option (something likebuck2 fmt
)?If there isn't a plan to bundle a formatter, would a contribution like this be well received?