-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Publishing this! #1
Comments
Hi -- glad you found this somewhat useful! Yes, I'd like to publish it but I'd like to find the time to really figure out how to do indentation first. Right now it sort of works but is much worse than tuareg, and I hit a bit of a wall trying replicate what tuareg does with smie. I did see that at least one other person (who is more involved in the OCaml community than myself) might be taking a stab at a tree-sitter mode. Could be worth reaching out to see how far they got. |
I dropped them an email and invited them to join forces with us. I don't think indentation needs to be as good as |
Hello! Thanks for the ping. I agree that it is better to join forces instead of having N separate half-baked TS modes. I worked a bit on the indentation part trying to replicate what https://github.com/OCamlPro/ocp-indent does (which is what I use at work), but it is far from perfect. You can see the code here: https://github.com/nojb/ocaml-ts-mode/blob/c1c36463d4db302405e792f6dbd65766ea1d1ec8/ocaml-ts-mode.el#L284-L308. Currently on holiday, but I am planning to try the mode in this repository when I get back to work next week and will report back here. Agree with #1 (comment) that it is OK to release something that is minimally working and improve it later. Editor modes have a low barrier to entry so once it is released many people can contribute improvements to it. |
Hey @nojb and @dmitrig, I wonder if I can do anything to help here. Perhaps I could grab @nojb's indent rules and add them to this version of the mode, perhaps as a separate PR, so that @dmitrig could try them out locally? Or perhaps we all think that @nojb's code might be a better starting point for a canonical |
Thanks for the ping @purcell. My 2c: forget indentation in the first release (indentation is also available with external packages such as I can't see a lot of my code has that is not already in this package, so I think it would be OK to go ahead with a preliminary release. I am planning to delete my repository soon to avoid confusion. |
Alternatively, leave what has been done already in the code, but make it very clear in the release that indentation support is experimental. That way, people will not complain if it doesn't match their expectations. |
Okay, so there are a couple of options I see:
I might suggest the latter, but happy with whatever @dmitrig prefers. |
Thanks for following up! I should have some time to move this forward this week. Re: what to do with indentation, I'll take a look at @nojb's code this afternoon but I think I agree now it doesn't matter much for the first release. I had started to compare indentation more systematically using the test cases in tuareg but it's still hard to say what's good enough short of matching exactly. So right now I think my plan is to try to clean up the code in its current state and put it on melpa this week, though I may still either replace or rip out the indentation logic and put it on a separate branch. Re permissions: happy to share commit privileges, though maybe we can hold off on making an org unless there's some benefit to that I'm not seeing. |
Was this deleted already? Getting a 404 @nojb |
Sorry, my bad. Should be fixed. |
Yep, just ping me and I can fast-track that part.
No particular benefit. |
Hey, I think I'll probably go ahead and add this to MELPA over the weekend, since it's honestly in good shape for a preview release. |
Okay, I added a MELPA recipe and it should start building there soon. :) |
Hi! I sat down and started writing an
ocaml-ts-mode
of my own for fun before thinking to search for a pre-existing one, and I found yours. You've made more progress (though I had some extra font lock rules), and it looks in pretty good shape overall, so how about we add yours to MELPA for wider use?The text was updated successfully, but these errors were encountered: