-
-
Notifications
You must be signed in to change notification settings - Fork 389
Add missing documentation for cabal formatters #4322
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -111,6 +111,7 @@ Completions for language pragmas. | |
## Formatting | ||
|
||
Format your code with various Haskell code formatters. | ||
The default Haskell code formatter is `ormolu`, and the Haskell formatter can be configured via the `formattingProvider` option. | ||
|
||
| Formatter | Provided by | | ||
| --------------- | ---------------------------- | | ||
|
@@ -119,12 +120,17 @@ Format your code with various Haskell code formatters. | |
| Ormolu | `hls-ormolu-plugin` | | ||
| Stylish Haskell | `hls-stylish-haskell-plugin` | | ||
|
||
--- | ||
|
||
Format your cabal files with a cabal code formatter. | ||
The default cabal code formatter is `cabal-gild`, which needs to be available on the `$PATH`, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This isn't a great experience, actually. So the default behaviour will send people errors, since most people won't have installed this? I think our default behaviour shouldn't rely on any external programs, which makes me think we should set the default cabal formatter to "none". There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. ... do we have a "none" formatting provider option? We maybe should do. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Hm, I thought we did. We definitely should have a "none" option. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yeah, the initial experience is not good. In the case of cabal-gild, we can likely ship it with all supported GHC versions. However, perhaps we should start shipping the binaries instead of linking it into HLS directly. Then every HLS version would have the same formatter version. Let's give #411 another kick. |
||
or the location needs to be explicitly provided. | ||
To change the cabal formatter, edit the `cabalFormattingProvider` option. | ||
|
||
| Formatter | Provided by | | ||
|-----------------|------------------------------| | ||
| cabal-fmt | `hls-cabal-fmt-plugin` | | ||
|
||
| cabal-gild | `hls-cabal-gild-plugin` | | ||
|
||
## Document symbols | ||
|
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
does this do anything?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Visual separation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this markdown syntax is usually translated to
<hr/>
in html, so should be fine.