diff options
author | Ben Sima <ben@bsima.me> | 2021-02-19 10:06:56 -0500 |
---|---|---|
committer | Ben Sima <ben@bsima.me> | 2021-02-19 10:06:56 -0500 |
commit | 64c5858f7bc01fa9c0e0bc5726066ce6167bea81 (patch) | |
tree | 85d8ee6ce02679c26bf1e59134eb5e88d9c5b272 /Biz | |
parent | c78119b0547cd9ef266db04a91a4d0e5be8340a8 (diff) |
Add support for hlint --refactor
Diffstat (limited to 'Biz')
-rw-r--r-- | Biz/Bild/Rules.nix | 1 | ||||
-rw-r--r-- | Biz/Bild/Sources.json | 26 | ||||
-rw-r--r-- | Biz/Lint.hs | 2 |
3 files changed, 28 insertions, 1 deletions
diff --git a/Biz/Bild/Rules.nix b/Biz/Bild/Rules.nix index 4875455..fb36100 100644 --- a/Biz/Bild/Rules.nix +++ b/Biz/Bild/Rules.nix @@ -136,6 +136,7 @@ in rec { [ p.black p.pylint ])) # tools + nixpkgs.haskell.packages.${ghcCompiler}.apply-refact nixpkgs.cmark nixpkgs.figlet nixpkgs.haskell.packages.${ghcCompiler}.fast-tags diff --git a/Biz/Bild/Sources.json b/Biz/Bild/Sources.json index 2aea2c8..934f658 100644 --- a/Biz/Bild/Sources.json +++ b/Biz/Bild/Sources.json @@ -1,4 +1,17 @@ { + "apply-refact": { + "branch": "master", + "description": "Refactor Haskell source files", + "homepage": "", + "owner": "mpickering", + "repo": "apply-refact", + "rev": "0.8.2.1", + "sha256": "0wyamn4w3lsayhsqs6h60f0m337b1p5byw1frmcyima3pqsgprvl", + "type": "tarball", + "url": "https://github.com/mpickering/apply-refact/archive/0.8.2.1.tar.gz", + "url_template": "https://github.com/<owner>/<repo>/archive/<rev>.tar.gz", + "version": "0.8.2.1" + }, "clay": { "branch": "master", "description": "A CSS preprocessor as embedded Haskell.", @@ -12,6 +25,19 @@ "url_template": "https://github.com/<owner>/<repo>/archive/<rev>.tar.gz", "version": "cc7729b1b42a79e261091ff7835f7fc2a7ae3cee" }, + "ghc-exactprint": { + "branch": "master", + "description": "GHC version of haskell-src-exts exactPrint", + "homepage": null, + "owner": "alanz", + "repo": "ghc-exactprint", + "rev": "3e70715a756c46761a3a6a086a6be5dee4e60d22", + "sha256": "1mhmk1555n7qr25iwbm8kbjs24c9j0q01j4m2kmz6zh7r1gjayxs", + "type": "tarball", + "url": "https://github.com/alanz/ghc-exactprint/archive/3e70715a756c46761a3a6a086a6be5dee4e60d22.tar.gz", + "url_template": "https://github.com/<owner>/<repo>/archive/<rev>.tar.gz", + "version": "0.6.3.4" + }, "ghcjs-base": { "branch": "master", "description": "base library for GHCJS for JavaScript interaction and marshalling, used by higher level libraries like JSC", diff --git a/Biz/Lint.hs b/Biz/Lint.hs index 17edb37..3039b72 100644 --- a/Biz/Lint.hs +++ b/Biz/Lint.hs @@ -117,7 +117,7 @@ hlint = Linter { exe = "hlint", args = [], - fixArgs = Nothing + fixArgs = Just ["--refactor", "--refactor-options=-i"] } pylint :: Linter |