elixir-editors / emacs-elixir

Emacs major mode for Elixir
448 stars 94 forks source link

tree-sitter support #494

Closed wingyplus closed 1 year ago

wingyplus commented 2 years ago

In upcoming emacs (29) they start supporting tree-sitter natively (not a separate package). It would be great if we supporting it. We already have tree-sitter-elixir https://github.com/elixir-lang/tree-sitter-elixir. And have someone already explore on tree-sitter emacs https://github.com/elixir-lang/tree-sitter-elixir/issues/4#issuecomment-1280030796.

victorolinasc commented 2 years ago

I think all the current contributors of emacs-elixir agrees this is a mostly welcome addition. We plan to support that and @wkirschbaum has already started implementing a version of it.

Things to consider here currently (2022-10-19):

Either way, this is certainly a great addition and will most likely provide a better developing experience.

victorolinasc commented 1 year ago

Giving some update here.

This is my take here. Please, chime in with your comments if this seems like a fair plan.

Thanks you all!

wkirschbaum commented 1 year ago

@victorolinasc elixir-ts-mode is already in core emacs, but only for 30. I actually started maintaining the mode on emacs core as an upstream.. I am also strongly considering adding a lightweight elixir-mode to core emacs later this year... but need to think about how and what this might mean.

elixir-ts-mode is in most popular support packages as well and should just work out of the box ( please log a bug if i missed one ).

wkirschbaum commented 1 year ago

the idea is to get elixir work as close to out of the box as possible with emacs with stable features, then have perhaps this or another package with fancier stuff. 🤷🏻. i have a elixir-compile-mode i want to add somewhere, but not sure where yet.

wkirschbaum commented 1 year ago

And I had some fun yesterday with Mitchell adding the credo language server to lsp-mode: https://github.com/emacs-lsp/lsp-mode/pull/4068

victorolinasc commented 1 year ago

That is awesome @wkirschbaum ! Thanks a lot for your work here :) I've been using elixir-ts-mode and it is shining. Much appreciated work here :)

I think we should, then, open an issue discussing a vision for Elixir in Emacs from here on out. My guess is that we think a bit alike here but it would be great to collect more feedback on how we should organize things in several projects.

It was suggested before to have a package that would:

Wdyt? We should re-up #465 there with a comment :)

wkirschbaum commented 1 year ago

@victorolinasc happy people are using it, lots to do still. specialized buffers would be nice.

victorolinasc commented 1 year ago

I will be closing this issue for now. We might change the readme to reflect things discussed here. If anyone wants to write and open a PR it would be greatly appreciated.