File tree 5 files changed +44
-266
lines changed
plugins/hls-cabal-fmt-plugin
5 files changed +44
-266
lines changed Original file line number Diff line number Diff line change @@ -9,7 +9,6 @@ packages:
9
9
./hls-plugin-api
10
10
./hls-test-utils
11
11
./plugins/hls-cabal-plugin
12
- ./plugins/hls-cabal-fmt-plugin
13
12
./plugins/hls-stylish-haskell-plugin
14
13
./plugins/hls-fourmolu-plugin
15
14
./plugins/hls-class-plugin
Original file line number Diff line number Diff line change @@ -83,9 +83,51 @@ flag cabalfmt
83
83
84
84
common cabalfmt
85
85
if flag(cabalfmt)
86
- build-depends : hls-cabal-fmt-plugin == 2.5.0.0
86
+ build-depends : hls-cabal-fmt-plugin
87
87
cpp-options : -Dhls_cabalfmt
88
88
89
+ flag isolateCabalfmtTests
90
+ description : Should tests search for 'cabal-fmt' on the $PATH or shall we install it via build-tool-depends?
91
+ -- By default, search on the PATH
92
+ default : False
93
+ manual : True
94
+
95
+ library hls-cabal-fmt-plugin
96
+ import : warnings
97
+ exposed-modules : Ide.Plugin.CabalFmt
98
+ hs-source-dirs : plugins/hls-cabal-fmt-plugin/src
99
+ build-depends :
100
+ , base >= 4.12 && < 5
101
+ , directory
102
+ , filepath
103
+ , ghcide == 2.5.0.0
104
+ , hls-plugin-api == 2.5.0.0
105
+ , lens
106
+ , lsp-types
107
+ , mtl
108
+ , process-extras
109
+ , text
110
+ , transformers
111
+
112
+ default-language : Haskell2010
113
+
114
+ test-suite hls-cabal-fmt-plugin-tests
115
+ import : warnings
116
+ type : exitcode-stdio-1.0
117
+ default-language : Haskell2010
118
+ hs-source-dirs : plugins/hls-cabal-fmt-plugin/test
119
+ main-is : Main.hs
120
+ ghc-options : -threaded -rtsopts -with-rtsopts=-N
121
+ build-depends :
122
+ , base
123
+ , directory
124
+ , filepath
125
+ , hls-cabal-fmt-plugin
126
+ , hls-test-utils == 2.5.0.0
127
+
128
+ if flag(isolateCabalfmtTests)
129
+ build-tool-depends : cabal-fmt :cabal-fmt ^>= 0.1.6
130
+
89
131
-----------------------------
90
132
-- cabal plugin
91
133
-----------------------------
Load Diff This file was deleted.
Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -57,4 +57,4 @@ cabalFmtGolden Found title path desc act = goldenWithCabalDocFormatter def cabal
57
57
conf = def
58
58
59
59
testDataDir :: FilePath
60
- testDataDir = " test" </> " testdata"
60
+ testDataDir = " plugins " </> " hls-cabal-fmt-plugin " </> " test" </> " testdata"
You can’t perform that action at this time.
0 commit comments