-
-
Notifications
You must be signed in to change notification settings - Fork 2.6k
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
F# for Helix? #4943
Comments
@MarkuBu There will be F# support when someone decides they want to add it. Maybe that person is you? https://docs.helix-editor.com/guides/adding_languages.html |
I'm a F# beginner, so probably not |
It seems there is no finished F# tree-sitter grammar (https://github.com/baronfel/tree-sitter-fsharp is very WIP), so I guess it's hard to get syntax highlights. |
That's not a good news :( |
This is sad, I just found Helix, and love it out of the box, but fsharp syntax highlighting is mandatory for me. Hope it will be added soon :) |
Status update here for future contributors:
|
After the F# tree-sitter implementation adds tree-sitter queries (which some plan to implement when the grammar stabilized), we should have everything to add F# support to Helix. However, the language server currently seems to be broken. I've tried to use the LSP server with Until that is fixed (or Helix enables a workaround), the F# language server is basically unusable. For now, I switched to VSCode for F#. This seems to be by far the best solution at the moment (and isn't too bad in combination with the |
This is pretty unofficial, but this is my working LSP config for using FSAC. Provides errors messages and jump to definition and other LSP stuff. The FSAC team is working, albeit slowly, on generalizing a lot of the endpoints that are Ionide (VSCode extension) specific. dotnet tool -g fsautocomplete [[language]]
name = "fsharp"
scope="source.fs"
roots = ["fsproj", "sln", ".git"]
injection-regex = "^fsharp$"
file-types = ["fs", "fsx", "fsi"]
comment-token = "//"
indent = { tab-width = 4, unit = " " }
auto-format = true
language-server = { command = "fsautocomplete", args = ["--verbose"] }
config = { AutomaticWorkspaceInit = true, FSharp.ExternalAutocomplete = true } |
@Eliemer: And this doesn't result in error messages after most cursor moves, as I've mentioned above? |
Also interested in this. |
Info:
I traversed through all the file, back and forth, up and down, then swapped
let fibs =
let rec f a b =
seq {
yield a
yield! f b (a + b)
}
f 1 1 |> Seq.cache
Seq.take 12 fibs |> Seq.skip 8
|
Thanks, @Eliemer. This sounds like there are no error messages displayed in the UI of Helix (which is what happened in Neovim). Maybe the messages that are logged as |
Theres still some dumb errors though. This happens when I introduce a newline at the start of the file. Results in an
|
Bump on this. Was able to try out the config of Eliemer. using FsAutoComplete v0.6.0 This worked as an LSP with some silly errors and bad log messages, but was largely usable in some quick testing. We're still going to need highlighting as a requirement, so https://github.com/Nsidorenco/tree-sitter-fsharp might be worth a look again if someone wants to give that a try in the current version and report back. |
🍾 |
I wonder why there is no support for F# in Helix until now. Is there any plan to add F# to Helix in the near future?
The text was updated successfully, but these errors were encountered: