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

637 Commits

Author SHA1 Message Date
Brandon Chinn
4e8fc16479 Implement Term as an AST builder + interpreters 2023-02-01 20:39:33 +01:00
Alexander Esgen
1b703670b5 Add Stack CI to keep stack.yaml up-to-date 2023-02-01 08:53:26 +01:00
Brandon Chinn
49ff8fb49d Fix stack build 2023-01-31 10:08:13 +01:00
Brandon Chinn
30531f008c Replace DList with Seq 2023-01-31 10:04:29 +01:00
Alexander Esgen
22c7a0b54e Update flake inputs, add GHC 9.4.4 to CI, minor tweaks 2023-01-27 12:09:06 +01:00
Mark Karpov
1b39d94d0c
Version bump (0.5.3.0) 2023-01-26 14:30:23 +01:00
Mark Karpov
c81320d8a1 Expose a more complete API from the Ormolu module
Co-authored-by: amesgen <alexander.esgen@tweag.io>
2023-01-25 20:27:25 +01:00
Mark Karpov
5a43ffc288 Gitignore .direnv/
This seems to be created when direnv uses a nix flake?
2023-01-24 20:32:38 +01:00
Alexander Esgen
4d62a7e062 Add WASM-based Ormolu Live
Co-authored-by: Mark Karpov <mark.karpov@tweag.io>
2023-01-24 18:45:36 +01:00
Alexander Esgen
81ae46ea9d Allow to disable bundling fixities
Should be reverted once the WASM backend supports TH.

Co-authored-by: Mark Karpov <mark.karpov@tweag.io>
2023-01-24 18:45:36 +01:00
Alexander Esgen
0bd2a7962c Support mtl-2.3
Various re-exports got removed.
2023-01-24 18:45:36 +01:00
Alexander Esgen
f0b8690ae1 Use Text as formatting input 2023-01-23 18:30:21 +01:00
Alexander Esgen
45eaf2a838 Don't use String for operator and package names 2023-01-23 18:30:21 +01:00
Alexander Esgen
af02809ebe Add GH Actions CI 2023-01-23 18:10:02 +01:00
Alexander Esgen
4b0bcc2945 Flakeify
also drop Ormolu Live temporarily
2023-01-23 18:10:02 +01:00
Mark Karpov
a4a9f4500b Normalize parentheses in constraints 2023-01-20 18:49:14 +01:00
Mark Karpov
9e4f22e14c Accept CRLF line endings in .ormolu files 2023-01-17 21:14:23 +01:00
Alexander Esgen
708de707ad Stop making empty lets move comments 2023-01-06 17:34:05 +01:00
Alexander Esgen
d8ef4d5d19 Remove last reference to JSON as the fixity DB format 2023-01-05 18:37:03 +01:00
Mark Karpov
810eb7839c
Version bump (0.5.2.0) 2023-01-05 16:15:37 +01:00
Alexander Esgen
a6dd9c16f5 Switch to binary for parsing the fixity DB 2023-01-05 16:11:05 +01:00
Mark Karpov
b64a5fd793 Default fixity to infixl 9 2023-01-05 14:04:46 +01:00
Alexander Esgen
19246fdda2 Regenerate extract-hackage-info/hackage-info.json 2023-01-05 09:41:51 +01:00
Alexander Esgen
960caaabec Fix Hackage extraction by reusing existing operator fixity parsers 2023-01-05 09:41:51 +01:00
Alexander Esgen
25c4ebb0ad Remove unused Lift instances and packages 2023-01-04 14:26:55 +01:00
Mark Karpov
b545930ca8 Eliminate the fixity-th cabal flag
The flag caused problems on GHC 9.4 and generally was a magnet for bugs, see
https://github.com/tweag/ormolu/issues/941 and
https://github.com/tweag/ormolu/issues/927. We are going to try to use
file-embed unconditionally and make parsing more efficient instead.

Co-authored-by: amesgen <alexander.esgen@tweag.io>
2023-01-03 16:33:02 +01:00
Simon Hengel
372bd0cee1 Git ignore .o-boot files 2023-01-03 15:27:33 +01:00
Simon Hengel
e7da6bc4c2 Don't use unsafePerformIO without need 2023-01-02 14:48:18 +01:00
Simon Hengel
9cdb3e93b0 Use it ".. instead of it "it .. 2023-01-02 14:15:42 +01:00
Alexander Esgen
0bcf31caef Disable fixity-th on GHC 9.4 2022-12-15 09:41:49 +01:00
Mark Karpov
1ec862c4e8
Version bump (0.5.1.0) 2022-11-14 17:30:07 +01:00
Alexander Esgen
6a26c134e4 Update CI for release binaries 2022-11-14 16:58:07 +01:00
Alexander Esgen
54642a7966 Switch to ghc-lib-parser-9.4 2022-11-09 19:43:22 +01:00
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