1
1
mirror of https://github.com/tweag/ormolu.git synced 2024-10-06 01:47:10 +03:00
Commit Graph

604 Commits

Author SHA1 Message Date
Brandon Chinn
1e68677e7d Fix an inconsistency in formatting of types in GADT declarations 2022-11-08 20:29:03 +01:00
Alexander Esgen
7bb7f7e47e Handle UnicodeSyntax variants more consistently 2022-11-08 19:38:56 +01:00
Alexander Esgen
570b3175a2 Support type applications in patterns 2022-11-02 16:49:16 +01:00
Alexander Esgen
8aef990d6c Fix formatting of SCC pragmas in do blocks 2022-09-30 17:42:03 +02:00
Alexander Esgen
ef18690191 Put extension packs like GHC2021 at the beginning 2022-09-22 21:03:32 +02:00
Matthew Healy
91ea909457 Add line numbers to Ormolu Live editor
This uses a pure-CSS solution to add line numbers to the text editor
in Ormolu Live. It calculates the desired line number count from the
input, and then creates an equivalent number of `span` elements. A
CSS counter is then incremented for each span, and the content is set
to the counter's value.
2022-08-22 19:05:57 +02:00
Matthew Healy
1dabb17e26 Fix typo in ormolu-live html script tag 2022-08-18 09:35:35 +02:00
Matthew Healy
f3ea558acb
Add a button to copy formatted code (#918) 2022-08-17 16:45:07 +02:00
Matthew Healy
00618737a4
Sort imports by package qualifier if present (#916)
This fixes #905 by sorting imports first by package qualifier,
if any are included, and then by module name. Imports without
package qualifiers are always sorted before those with.
2022-08-16 17:19:29 +02:00
Mark Karpov
f80f4ec20d
Version bump (0.5.0.1) 2022-08-05 16:26:26 +02:00
Alexander Esgen
3bd79c0869 Cache .cabal file parsing and processing 2022-08-05 16:25:29 +02:00
Mark Karpov
5baf431ebb Indent comments in closed type familiy declarations 2022-08-02 18:59:08 +02:00
Alexander Esgen
84a3f0eaba Cabal file lookup: fix handling of hs-source-dirs: . 2022-07-19 19:11:49 +02:00
Alexander Esgen
7fc42d1929 Indent closing bracket for list comprehensions in do blocks 2022-06-14 19:54:53 +02:00
Mark Karpov
25b04d45b4 Fix some bugs in the diff printing code 2022-05-15 22:11:41 +02:00
Mark Karpov
5e66897613
Version bump (0.5.0.0) 2022-05-12 14:07:54 +02:00
Mark Karpov
246b36a4c8
Fix a warning in Ormolu live 2022-05-12 14:07:54 +02:00
Mark Karpov
4b5ba705d7 Introduce operator fixity configuration
Co-authored-by: amesgen <alexander.esgen@tweag.io>
2022-05-12 13:50:42 +02:00
Mark Karpov
e2eda075a0 Regenerate extract-hackage-info/hackage-info.json 2022-05-11 18:37:44 +02:00
Mark Karpov
b13a5aedfe Fix Hackage info extraction, add a script for that
Hackage extraction script was broken because
https://hackage.haskell.org/packages/browse had been converted to a
JavaScript-powered page. We try to extract the same data from a different
page and automate the process.
2022-05-11 18:37:44 +02:00
Mark Karpov
276dfdd9a2 Fix formatting of single-constructor record with a Haddock 2022-05-11 17:58:06 +02:00
Georgi Lyubenov
1ffd51ab3e Update the IOHK Hydra setup instructions 2022-05-09 09:33:07 +02:00
Mark Karpov
903b5c59fb Make errors about AST differences print diffs
Print the diff between the original input and the erroneous result that
Ormolu produces. Also mention --unsafe in the error message.

Co-authored-by: Alexander Esgen <alexander.esgen@tweag.io>
2022-05-04 21:16:05 +02:00
Alexander Esgen
32abe9f52a Remove discrepancies between unboxed types and terms 2022-04-10 21:20:22 +02:00
Brandon Chinn
5f0a597842 Add back sitcc to ExplicitTuple.p_arg 2022-04-08 21:43:01 +02:00
Brandon Chinn
9ef1368d15 Fix stack for ormolu-live + extract-hackage-info 2022-04-05 10:01:07 +02:00
Brandon Chinn
2377390f94 Fix stack.yaml 2022-04-04 08:56:31 +02:00
Alexander Esgen
8fa481d42a Move script tag into the body 2022-02-22 19:52:58 +01:00
Alexander Esgen
376ffcccb5 Bump nixpkgs via haskell.nix for macdylibbundler 1.0.4 2022-02-16 11:23:45 +01:00
Mark Karpov
f32cd8ef26 Update versions of some dependencies, update haskell.nix 2022-02-08 21:54:14 +01:00
Alexander Esgen
8f95c53b2a Allow non-blank text after magic comments 2022-01-24 11:02:41 +01:00
Farseen
3f06ef0dc9 Mention actively maintained forks in the readme 2022-01-10 09:32:37 +01:00
Alexander Esgen
b9eaa3d9a7 Remove lib.mkIf workaround 2021-12-31 15:10:28 +01:00
Mark Karpov
63ec971f4c Make sure to format all cabal files, sort dependencies 2021-12-17 20:19:24 +01:00
Thomas BAGREL
aa9ea5e906 Handle multi-operator fixity declarations in the extraction script 2021-12-17 19:46:23 +01:00
Mark Karpov
d477a0be37 Rename Ormolu.Fixity.Types to Ormolu.Fixity.Internal
I think `Internal` makes it more obvious that the module is not part of the
public API (e.g. the data constructor of `LazyFixityMap` should normally
stay hidden).
2021-12-17 15:56:55 +01:00
Alexander Esgen
57540cf34b Ormolu Live: Propagate fixity map cache at startup 2021-12-17 15:23:07 +01:00
Mark Karpov
9418227302 Format bidirectional pattern synonyms nicer 2021-12-17 15:10:00 +01:00
Alexander Esgen
e3ad839959 Cache operator fixity maps 2021-12-17 14:37:44 +01:00
Mark Karpov
72054360f5 Move defaultFixityMap to Ormolu live 2021-12-16 23:26:53 +01:00
Thomas BAGREL
1f63136d04 Operator chain overhaul
See the changelog for details.

Co-authored-by: Alexander Esgen <alexander.esgen@tweag.io>
Co-authored-by: Mark Karpov <mark.karpov@tweag.io>
2021-12-16 16:23:57 +01:00
Mark Karpov
551faf3ee9
Update the author and maintainer fields of Ormolu live 2021-12-13 20:10:21 +01:00
Alexander Esgen
2c52cff9ea Add haskell-language-server to dev shell 2021-12-08 19:27:49 +01:00
Mark Karpov
47f31ac1c7
Update the CONTRIBUTING.md file 2021-12-02 22:45:37 +01:00
amesgen
42550a2bbd Use graphql-engine from nixpkgs
It now points to an up-to-date version.
2021-11-30 18:25:42 +01:00
amesgen
308542e06a Fix type synonyms with comment before = 2021-11-30 16:32:12 +01:00
Thomas BAGREL
d0e558d05b Escape invalid haddock comments 2021-11-29 17:20:58 +01:00
Mark Karpov
807ee05aee
Version bump (0.4.0.0) 2021-11-29 13:27:30 +01:00
amesgen
3781d37488 Rebuild all GHCJS dependencies by upgrading haskell.nix 2021-11-17 17:25:33 +01:00
amesgen
e813e5781e Use custom macdylibbundler 2021-11-17 17:02:54 +01:00