You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It's a bit cumbersome to write our new tree-sitter queries (#616) because there is no autoformatter. I don't know of one today, but we could probably write one by leveraging the tree-sitter parser for tree-sitter-query. We might want to build the formatter using dprint. A couple possibly useful resources on dprint:
This autoformatter would obviously be useful outside of Cursorless for the many other projects writing tree-sitter queries
Update: today we're relying on @AndreasArvidsson's VSCode extension to do autoformatting for scm files, which is great for development, but doesn't support CI.
Also, per @auscompgeek's suggestion, we may want to consider writing the formatter as a prettier plugin. I poked through the docs a bit and from what I saw it looks like it's potentially a nice fit
We may also consider using https://topiary.tweag.io/, which has experimental support for formatting .scm files, but as of 2023-12-01 doesn't yet have a VSCode extension (see tweag/topiary#655 to track)
The text was updated successfully, but these errors were encountered:
It's a bit cumbersome to write our new tree-sitter queries (#616) because there is no autoformatter. I don't know of one today, but we could probably write one by leveraging the tree-sitter parser for tree-sitter-query. We might want to build the formatter using dprint. A couple possibly useful resources on dprint:
Alternately, we might look into using the machinery that @wenkokke developed for https://github.com/wenkokke/talonfmt
This autoformatter would obviously be useful outside of Cursorless for the many other projects writing tree-sitter queries
Update: today we're relying on @AndreasArvidsson's VSCode extension to do autoformatting for scm files, which is great for development, but doesn't support CI.
Also, per @auscompgeek's suggestion, we may want to consider writing the formatter as a prettier plugin. I poked through the docs a bit and from what I saw it looks like it's potentially a nice fit
We may also consider using https://topiary.tweag.io/, which has experimental support for formatting
.scm
files, but as of 2023-12-01 doesn't yet have a VSCode extension (see tweag/topiary#655 to track)The text was updated successfully, but these errors were encountered: