tangled
alpha
login
or
join now
pyrox.dev
/
nixpkgs
0
fork
atom
lol
0
fork
atom
overview
issues
pulls
pipelines
Add haskell-ide-engine
Shea Levy
8 years ago
961907de
4026ea9c
+508
-1
5 changed files
expand all
collapse all
unified
split
pkgs
development
haskell-modules
configuration-common.nix
default.nix
hie-packages.nix
initial-packages.nix
patches
hie-testsuite.patch
+6
pkgs/development/haskell-modules/configuration-common.nix
reviewed
···
1012
1012
{ patches = (drv.patches or []) ++ [ patch ];
1013
1013
editedCabalFile = null;
1014
1014
});
1015
1015
+
1016
1016
+
# https://github.com/haskell/cabal/issues/4969
1017
1017
+
haddock-library_1_4_4 = dontHaddock super.haddock-library_1_4_4;
1018
1018
+
1019
1019
+
haddock-api = super.haddock-api.override
1020
1020
+
{ haddock-library = self.haddock-library_1_4_4; };
1015
1021
}
+1
-1
pkgs/development/haskell-modules/default.nix
reviewed
···
2
2
, compilerConfig ? (self: super: {})
3
3
, packageSetConfig ? (self: super: {})
4
4
, overrides ? (self: super: {})
5
5
-
, initialPackages ? import ./hackage-packages.nix
5
5
+
, initialPackages ? import ./initial-packages.nix
6
6
, configurationCommon ? import ./configuration-common.nix
7
7
, configurationNix ? import ./configuration-nix.nix
8
8
}:
+459
pkgs/development/haskell-modules/hie-packages.nix
reviewed
···
1
1
+
{ pkgs, stdenv, callPackage }: self:
2
2
+
let src = pkgs.fetchFromGitHub
3
3
+
{ owner = "haskell";
4
4
+
repo = "haskell-ide-engine";
5
5
+
rev = "3ec8e93e9ca751cf282556998851ffa65f32e06b";
6
6
+
sha256 = "1wzqzvsa39c1cngmmjryqrq4vqdg6d4wp5wdf17vp96ljvz1cczw";
7
7
+
};
8
8
+
cabal-helper-src = pkgs.fetchgit
9
9
+
{ url = "https://gitlab.com/dxld/cabal-helper.git";
10
10
+
rev = "4bfc6b916fcc696a5d82e7cd35713d6eabcb0533";
11
11
+
sha256 = "1a8231as0wdvi0q73ha9lc0qrx23kmcwf910qaicvmdar5p2b15m";
12
12
+
};
13
13
+
ghc-dump-tree-src = pkgs.fetchgit
14
14
+
{ url = "https://gitlab.com/alanz/ghc-dump-tree.git";
15
15
+
rev = "50f8b28fda675cca4df53909667c740120060c49";
16
16
+
sha256 = "0v3r81apdqp91sv7avy7f0s3im9icrakkggw8q5b7h0h4js6irqj";
17
17
+
};
18
18
+
ghc-mod-src = pkgs.fetchFromGitHub
19
19
+
{ owner = "wz1000";
20
20
+
repo = "ghc-mod";
21
21
+
rev = "03c91ea53b6389e7a1fcf4e471171aa3d6c8de41";
22
22
+
sha256 = "11iic93klsh5izp8v4mhl7vnnlib821cfhdymlpg4drx7zbm9il6";
23
23
+
};
24
24
+
HaRe-src = pkgs.fetchgit
25
25
+
{ url = "https://gitlab.com/alanz/HaRe.git";
26
26
+
rev = "e325975450ce89d790ed3f92de3ef675967d9538";
27
27
+
sha256 = "0z7r3l4j5a1brz7zb2rgd985m58rs0ki2p59y1l9i46fcy8r9y4g";
28
28
+
};
29
29
+
cabal-helper = self.cabal-helper_hie;
30
30
+
haddock-library = self.haddock-library_1_4_4;
31
31
+
ghc-dump-tree = self.ghc-dump-tree_hie;
32
32
+
ghc-mod = self.ghc-mod_hie;
33
33
+
HaRe = self.HaRe_hie;
34
34
+
in
35
35
+
{ ### Overrides required by hie
36
36
+
cabal-helper_hie = callPackage
37
37
+
({ mkDerivation, base, bytestring, Cabal, cabal-install, containers
38
38
+
, directory, exceptions, filepath, ghc-prim, mtl, process
39
39
+
, semigroupoids, template-haskell, temporary, transformers
40
40
+
, unix, unix-compat, utf8-string
41
41
+
}:
42
42
+
mkDerivation {
43
43
+
pname = "cabal-helper";
44
44
+
version = "0.8.0.0";
45
45
+
src = cabal-helper-src;
46
46
+
isLibrary = true;
47
47
+
isExecutable = true;
48
48
+
jailbreak = true;
49
49
+
setupHaskellDepends = [ base Cabal directory filepath ];
50
50
+
libraryHaskellDepends = [
51
51
+
base Cabal directory filepath ghc-prim mtl process semigroupoids
52
52
+
transformers unix unix-compat
53
53
+
];
54
54
+
executableHaskellDepends = [
55
55
+
base bytestring Cabal containers directory exceptions filepath
56
56
+
ghc-prim mtl process template-haskell temporary transformers unix
57
57
+
unix-compat utf8-string
58
58
+
];
59
59
+
testHaskellDepends = [
60
60
+
base bytestring Cabal directory exceptions filepath ghc-prim mtl
61
61
+
process template-haskell temporary transformers unix unix-compat
62
62
+
utf8-string
63
63
+
];
64
64
+
testToolDepends = [ cabal-install ];
65
65
+
postInstall =
66
66
+
''
67
67
+
libexec="$out/libexec/$(basename $out/lib/ghc*/*ghc*)/$name"
68
68
+
mkdir -p "$libexec"
69
69
+
ln -sv $out/bin/cabal-helper-wrapper "$libexec"
70
70
+
'';
71
71
+
doCheck = false;
72
72
+
description = "Simple interface to some of Cabal's configuration state, mainly used by ghc-mod";
73
73
+
license = stdenv.lib.licenses.agpl3;
74
74
+
}) {};
75
75
+
ghc-dump-tree_hie = callPackage
76
76
+
({ mkDerivation, aeson, base, bytestring, ghc, optparse-applicative
77
77
+
, pretty, pretty-show, process, unordered-containers
78
78
+
, vector
79
79
+
}:
80
80
+
mkDerivation {
81
81
+
pname = "ghc-dump-tree";
82
82
+
version = "0.2.0.1";
83
83
+
src = ghc-dump-tree-src;
84
84
+
isLibrary = true;
85
85
+
isExecutable = true;
86
86
+
libraryHaskellDepends = [
87
87
+
aeson base bytestring ghc pretty pretty-show process
88
88
+
unordered-containers vector
89
89
+
];
90
90
+
executableHaskellDepends = [
91
91
+
aeson base bytestring ghc optparse-applicative pretty pretty-show
92
92
+
process unordered-containers vector
93
93
+
];
94
94
+
homepage = "https://github.com/edsko/ghc-dump-tree";
95
95
+
description = "Dump GHC's parsed, renamed, and type checked ASTs";
96
96
+
license = stdenv.lib.licenses.bsd3;
97
97
+
}) {};
98
98
+
ghc-mod-core = callPackage
99
99
+
({ mkDerivation, base, binary, bytestring, Cabal, cabal-helper
100
100
+
, containers, deepseq, directory, djinn-ghc, extra, fclabels
101
101
+
, filepath, fingertree, ghc, ghc-boot, ghc-paths, ghc-syb-utils
102
102
+
, haskell-src-exts, hlint, monad-control, monad-journal, mtl
103
103
+
, old-time, optparse-applicative, pipes, process, safe, semigroups
104
104
+
, split, syb, template-haskell, temporary, text, time
105
105
+
, transformers, transformers-base
106
106
+
}:
107
107
+
mkDerivation {
108
108
+
pname = "ghc-mod-core";
109
109
+
version = "5.9.0.0";
110
110
+
src = "${ghc-mod-src}/core";
111
111
+
setupHaskellDepends = [
112
112
+
base Cabal containers directory filepath process template-haskell
113
113
+
transformers
114
114
+
];
115
115
+
libraryHaskellDepends = [
116
116
+
base binary bytestring cabal-helper containers deepseq directory
117
117
+
djinn-ghc extra fclabels filepath fingertree ghc ghc-boot ghc-paths
118
118
+
ghc-syb-utils haskell-src-exts hlint monad-control monad-journal
119
119
+
mtl old-time optparse-applicative pipes process safe semigroups
120
120
+
split syb template-haskell temporary text time transformers
121
121
+
transformers-base
122
122
+
];
123
123
+
homepage = "https://github.com/DanielG/ghc-mod";
124
124
+
description = "Happy Haskell Hacking";
125
125
+
license = stdenv.lib.licenses.agpl3;
126
126
+
}) { inherit cabal-helper; };
127
127
+
ghc-mod_hie = callPackage
128
128
+
({ mkDerivation, base, binary, bytestring, Cabal, cabal-doctest
129
129
+
, cabal-helper, containers, criterion, deepseq, directory
130
130
+
, djinn-ghc, doctest, extra, fclabels, filepath, ghc, ghc-boot
131
131
+
, ghc-mod-core, ghc-paths, ghc-syb-utils, haskell-src-exts, hlint
132
132
+
, hspec, monad-control, monad-journal, mtl, old-time
133
133
+
, optparse-applicative, pipes, process, safe, semigroups, shelltest
134
134
+
, split, syb, template-haskell, temporary, text, time
135
135
+
, transformers, transformers-base
136
136
+
}:
137
137
+
mkDerivation {
138
138
+
pname = "ghc-mod";
139
139
+
version = "5.9.0.0";
140
140
+
src = ghc-mod-src;
141
141
+
isLibrary = true;
142
142
+
isExecutable = true;
143
143
+
enableSeparateDataOutput = true;
144
144
+
setupHaskellDepends = [
145
145
+
base Cabal cabal-doctest containers directory filepath process
146
146
+
template-haskell transformers
147
147
+
];
148
148
+
libraryHaskellDepends = [
149
149
+
base binary bytestring cabal-helper containers deepseq directory
150
150
+
djinn-ghc extra fclabels filepath ghc ghc-boot ghc-mod-core
151
151
+
ghc-paths ghc-syb-utils haskell-src-exts hlint monad-control
152
152
+
monad-journal mtl old-time optparse-applicative pipes process safe
153
153
+
semigroups split syb template-haskell temporary text time
154
154
+
transformers transformers-base
155
155
+
];
156
156
+
executableHaskellDepends = [
157
157
+
base binary deepseq directory fclabels filepath ghc ghc-mod-core
158
158
+
monad-control mtl old-time optparse-applicative process semigroups
159
159
+
split time
160
160
+
];
161
161
+
testHaskellDepends = [
162
162
+
base cabal-helper containers directory doctest fclabels filepath
163
163
+
ghc ghc-boot ghc-mod-core hspec monad-journal mtl process split
164
164
+
temporary transformers
165
165
+
];
166
166
+
testToolDepends = [ shelltest ];
167
167
+
# Doesn't work with our doctest
168
168
+
doCheck = false;
169
169
+
benchmarkHaskellDepends = [
170
170
+
base criterion directory filepath ghc-mod-core temporary
171
171
+
];
172
172
+
homepage = "https://github.com/DanielG/ghc-mod";
173
173
+
description = "Happy Haskell Hacking";
174
174
+
license = stdenv.lib.licenses.agpl3;
175
175
+
}) { shelltest = null; inherit cabal-helper; };
176
176
+
HaRe_hie = callPackage
177
177
+
({ mkDerivation, attoparsec, base, base-prelude, Cabal, cabal-helper
178
178
+
, case-insensitive, containers, conversion
179
179
+
, conversion-case-insensitive, conversion-text, Diff, directory
180
180
+
, filepath, foldl, ghc, ghc-exactprint, ghc-mod-core, ghc-syb-utils
181
181
+
, gitrev, hslogger, hspec, HUnit, monad-control, mtl
182
182
+
, optparse-applicative, optparse-simple, parsec, stdenv
183
183
+
, Strafunski-StrategyLib, syb, syz, turtle
184
184
+
}:
185
185
+
mkDerivation {
186
186
+
pname = "HaRe";
187
187
+
version = "0.8.4.1";
188
188
+
src = HaRe-src;
189
189
+
isLibrary = true;
190
190
+
isExecutable = true;
191
191
+
enableSeparateDataOutput = true;
192
192
+
libraryHaskellDepends = [
193
193
+
base cabal-helper containers directory filepath ghc ghc-exactprint
194
194
+
ghc-mod-core ghc-syb-utils hslogger monad-control mtl
195
195
+
Strafunski-StrategyLib syb syz
196
196
+
];
197
197
+
executableHaskellDepends = [
198
198
+
base Cabal ghc-mod-core gitrev mtl optparse-applicative
199
199
+
optparse-simple
200
200
+
];
201
201
+
testHaskellDepends = [
202
202
+
attoparsec base base-prelude cabal-helper case-insensitive
203
203
+
containers conversion conversion-case-insensitive conversion-text
204
204
+
Diff directory filepath foldl ghc ghc-exactprint ghc-mod-core
205
205
+
ghc-syb-utils hslogger hspec HUnit monad-control mtl parsec
206
206
+
Strafunski-StrategyLib syb syz turtle
207
207
+
];
208
208
+
# Test directory doesn't exist
209
209
+
doCheck = false;
210
210
+
homepage = "https://github.com/RefactoringTools/HaRe/wiki";
211
211
+
description = "the Haskell Refactorer";
212
212
+
license = stdenv.lib.licenses.bsd3;
213
213
+
}) { inherit cabal-helper; };
214
214
+
### hie packages
215
215
+
haskell-ide-engine = callPackage
216
216
+
({ mkDerivation, aeson, async, base, bytestring, Cabal, cabal-install
217
217
+
, containers, data-default, Diff, directory, either, ekg, filepath, ghc
218
218
+
, ghc-mod-core, gitrev, haskell-lsp, hie-apply-refact, hie-base
219
219
+
, hie-brittany, hie-build-plugin, hie-eg-plugin-async
220
220
+
, hie-example-plugin2, hie-ghc-mod, hie-ghc-tree, hie-haddock
221
221
+
, hie-hare, hie-hoogle, hie-plugin-api, hoogle, hslogger, hspec
222
222
+
, lens, mtl, optparse-simple, QuickCheck, quickcheck-instances
223
223
+
, sorted-list, stm, text, time, transformers
224
224
+
, unordered-containers, vector, vinyl, yaml, yi-rope
225
225
+
}:
226
226
+
mkDerivation {
227
227
+
pname = "haskell-ide-engine";
228
228
+
version = "0.1.0.0";
229
229
+
inherit src;
230
230
+
isLibrary = true;
231
231
+
isExecutable = true;
232
232
+
libraryHaskellDepends = [
233
233
+
aeson async base bytestring Cabal containers data-default directory
234
234
+
either filepath ghc ghc-mod-core gitrev haskell-lsp
235
235
+
hie-apply-refact hie-base hie-brittany hie-ghc-mod hie-haddock
236
236
+
hie-hare hie-hoogle hie-plugin-api hslogger lens mtl
237
237
+
optparse-simple sorted-list stm text transformers
238
238
+
unordered-containers vector yi-rope
239
239
+
];
240
240
+
executableHaskellDepends = [
241
241
+
base Cabal containers directory ekg ghc-mod-core gitrev haskell-lsp
242
242
+
hie-apply-refact hie-build-plugin hie-eg-plugin-async
243
243
+
hie-example-plugin2 hie-ghc-mod hie-ghc-tree hie-hare hie-hoogle
244
244
+
hie-plugin-api hslogger optparse-simple stm text time transformers
245
245
+
unordered-containers vinyl
246
246
+
];
247
247
+
testHaskellDepends = [
248
248
+
aeson base containers Diff directory filepath ghc-mod-core
249
249
+
haskell-lsp hie-apply-refact hie-base hie-eg-plugin-async
250
250
+
hie-example-plugin2 hie-ghc-mod hie-ghc-tree hie-hare hie-hoogle
251
251
+
hie-plugin-api hoogle hslogger hspec QuickCheck
252
252
+
quickcheck-instances stm text transformers unordered-containers
253
253
+
vector vinyl yaml
254
254
+
];
255
255
+
preCheck = "export HOME=$NIX_BUILD_TOP/home; mkdir $HOME";
256
256
+
# https://github.com/haskell/haskell-ide-engine/issues/425
257
257
+
# The disabled tests do work in a local nix-shell with cabal available.
258
258
+
patches = [ ./patches/hie-testsuite.patch ];
259
259
+
homepage = "http://github.com/githubuser/haskell-ide-engine#readme";
260
260
+
description = "Provide a common engine to power any Haskell IDE";
261
261
+
license = stdenv.lib.licenses.bsd3;
262
262
+
}) {};
263
263
+
hie-apply-refact = callPackage
264
264
+
({ mkDerivation, aeson, apply-refact, base, either, extra, ghc-mod
265
265
+
, ghc-mod-core, haskell-src-exts, hie-base, hie-plugin-api, hlint
266
266
+
, text, transformers
267
267
+
}:
268
268
+
mkDerivation {
269
269
+
pname = "hie-apply-refact";
270
270
+
version = "0.1.0.0";
271
271
+
inherit src;
272
272
+
postUnpack = "sourceRoot=source/hie-apply-refact";
273
273
+
libraryHaskellDepends = [
274
274
+
aeson apply-refact base either extra ghc-mod ghc-mod-core
275
275
+
haskell-src-exts hie-base hie-plugin-api hlint text transformers
276
276
+
];
277
277
+
description = "Haskell IDE Apply Refact plugin";
278
278
+
license = stdenv.lib.licenses.bsd3;
279
279
+
}) { inherit ghc-mod; };
280
280
+
hie-base = callPackage
281
281
+
({ mkDerivation, aeson, base, haskell-lsp, text }:
282
282
+
mkDerivation {
283
283
+
pname = "hie-base";
284
284
+
version = "0.1.0.0";
285
285
+
inherit src;
286
286
+
preUnpack = "sourceRoot=source/hie-base";
287
287
+
libraryHaskellDepends = [ aeson base haskell-lsp text ];
288
288
+
description = "Haskell IDE API base types";
289
289
+
license = stdenv.lib.licenses.bsd3;
290
290
+
}) {};
291
291
+
hie-brittany = callPackage
292
292
+
({ mkDerivation, aeson, base, brittany, ghc-mod, ghc-mod-core
293
293
+
, haskell-lsp, hie-plugin-api, lens, text
294
294
+
}:
295
295
+
mkDerivation {
296
296
+
pname = "hie-brittany";
297
297
+
version = "0.1.0.0";
298
298
+
inherit src;
299
299
+
postUnpack = "sourceRoot=source/hie-brittany";
300
300
+
libraryHaskellDepends = [
301
301
+
aeson base brittany ghc-mod ghc-mod-core haskell-lsp hie-plugin-api
302
302
+
lens text
303
303
+
];
304
304
+
description = "Haskell IDE Hoogle plugin";
305
305
+
license = stdenv.lib.licenses.bsd3;
306
306
+
}) { inherit ghc-mod; };
307
307
+
hie-build-plugin = callPackage
308
308
+
({ mkDerivation, aeson, base, bytestring, Cabal, cabal-helper
309
309
+
, containers, directory, filepath, haskell-lsp, hie-plugin-api
310
310
+
, process, stm, text, transformers, yaml
311
311
+
}:
312
312
+
mkDerivation {
313
313
+
pname = "hie-build-plugin";
314
314
+
version = "0.1.0.0";
315
315
+
inherit src;
316
316
+
postUnpack = "sourceRoot=source/hie-build-plugin";
317
317
+
libraryHaskellDepends = [
318
318
+
aeson base bytestring Cabal cabal-helper containers directory
319
319
+
filepath haskell-lsp hie-plugin-api process stm text transformers
320
320
+
yaml
321
321
+
];
322
322
+
description = "Haskell IDE build plugin";
323
323
+
license = stdenv.lib.licenses.bsd3;
324
324
+
}) { inherit cabal-helper; };
325
325
+
hie-eg-plugin-async = callPackage
326
326
+
({ mkDerivation, base, ghc-mod-core, hie-plugin-api, stm
327
327
+
, text
328
328
+
}:
329
329
+
mkDerivation {
330
330
+
pname = "hie-eg-plugin-async";
331
331
+
version = "0.1.0.0";
332
332
+
inherit src;
333
333
+
postUnpack = "sourceRoot=source/hie-eg-plugin-async";
334
334
+
libraryHaskellDepends = [
335
335
+
base ghc-mod-core hie-plugin-api stm text
336
336
+
];
337
337
+
description = "Haskell IDE example plugin, using async processes";
338
338
+
license = stdenv.lib.licenses.bsd3;
339
339
+
}) {};
340
340
+
hie-example-plugin2 = callPackage
341
341
+
({ mkDerivation, base, hie-plugin-api, text }:
342
342
+
mkDerivation {
343
343
+
pname = "hie-example-plugin2";
344
344
+
version = "0.1.0.0";
345
345
+
inherit src;
346
346
+
postUnpack = "sourceRoot=source/hie-example-plugin2";
347
347
+
libraryHaskellDepends = [ base hie-plugin-api text ];
348
348
+
description = "Haskell IDE example plugin";
349
349
+
license = stdenv.lib.licenses.bsd3;
350
350
+
}) {};
351
351
+
hie-ghc-mod = callPackage
352
352
+
({ mkDerivation, aeson, base, containers, ghc, ghc-mod, ghc-mod-core
353
353
+
, hie-base, hie-plugin-api, text, transformers
354
354
+
}:
355
355
+
mkDerivation {
356
356
+
pname = "hie-ghc-mod";
357
357
+
version = "0.1.0.0";
358
358
+
inherit src;
359
359
+
postUnpack = "sourceRoot=source/hie-ghc-mod";
360
360
+
libraryHaskellDepends = [
361
361
+
aeson base containers ghc ghc-mod ghc-mod-core hie-base
362
362
+
hie-plugin-api text transformers
363
363
+
];
364
364
+
description = "Haskell IDE ghc-mod plugin";
365
365
+
license = stdenv.lib.licenses.bsd3;
366
366
+
}) { inherit ghc-mod; };
367
367
+
hie-ghc-tree = callPackage
368
368
+
({ mkDerivation, aeson, base, ghc-dump-tree, ghc-mod, ghc-mod-core
369
369
+
, hie-base, hie-plugin-api, text
370
370
+
}:
371
371
+
mkDerivation {
372
372
+
pname = "hie-ghc-tree";
373
373
+
version = "0.1.0.0";
374
374
+
inherit src;
375
375
+
postUnpack = "sourceRoot=source/hie-ghc-tree";
376
376
+
libraryHaskellDepends = [
377
377
+
aeson base ghc-dump-tree ghc-mod ghc-mod-core hie-base
378
378
+
hie-plugin-api text
379
379
+
];
380
380
+
description = "Haskell IDE GHC Tree plugin";
381
381
+
license = stdenv.lib.licenses.bsd3;
382
382
+
}) { inherit ghc-dump-tree ghc-mod; };
383
383
+
hie-haddock = callPackage
384
384
+
({ mkDerivation, aeson, base, containers, directory, either
385
385
+
, filepath, ghc, ghc-exactprint, ghc-mod, ghc-mod-core, haddock-api
386
386
+
, haddock-library, HaRe, haskell-lsp, hie-base, hie-ghc-mod
387
387
+
, hie-hare, hie-plugin-api, lens, monad-control, mtl, text
388
388
+
, transformers
389
389
+
}:
390
390
+
mkDerivation {
391
391
+
pname = "hie-haddock";
392
392
+
version = "0.1.0.0";
393
393
+
inherit src;
394
394
+
postUnpack = "sourceRoot=source/hie-haddock";
395
395
+
libraryHaskellDepends = [
396
396
+
aeson base containers directory either filepath ghc ghc-exactprint
397
397
+
ghc-mod ghc-mod-core haddock-api haddock-library HaRe haskell-lsp
398
398
+
hie-base hie-ghc-mod hie-hare hie-plugin-api lens monad-control mtl
399
399
+
text transformers
400
400
+
];
401
401
+
description = "Haskell IDE Haddock plugin";
402
402
+
license = stdenv.lib.licenses.bsd3;
403
403
+
}) { inherit haddock-library HaRe ghc-mod; };
404
404
+
hie-hare = callPackage
405
405
+
({ mkDerivation, aeson, base, containers, Diff, either, ghc
406
406
+
, ghc-exactprint, ghc-mod, ghc-mod-core, HaRe, haskell-lsp
407
407
+
, hie-base, hie-ghc-mod, hie-plugin-api, lens, monad-control, mtl
408
408
+
, text, transformers
409
409
+
}:
410
410
+
mkDerivation {
411
411
+
pname = "hie-hare";
412
412
+
version = "0.1.0.0";
413
413
+
inherit src;
414
414
+
postUnpack = "sourceRoot=source/hie-hare";
415
415
+
libraryHaskellDepends = [
416
416
+
aeson base containers Diff either ghc ghc-exactprint ghc-mod
417
417
+
ghc-mod-core HaRe haskell-lsp hie-base hie-ghc-mod hie-plugin-api
418
418
+
lens monad-control mtl text transformers
419
419
+
];
420
420
+
description = "Haskell IDE HaRe plugin";
421
421
+
license = stdenv.lib.licenses.bsd3;
422
422
+
}) { inherit ghc-mod HaRe; };
423
423
+
hie-hoogle = callPackage
424
424
+
({ mkDerivation, aeson, base, directory, filepath, ghc-mod
425
425
+
, ghc-mod-core, hie-plugin-api, hoogle, tagsoup, text
426
426
+
}:
427
427
+
mkDerivation {
428
428
+
pname = "hie-hoogle";
429
429
+
version = "0.1.0.0";
430
430
+
inherit src;
431
431
+
postUnpack = "sourceRoot=source/hie-hoogle";
432
432
+
libraryHaskellDepends = [
433
433
+
aeson base directory filepath ghc-mod ghc-mod-core hie-plugin-api
434
434
+
hoogle tagsoup text
435
435
+
];
436
436
+
description = "Haskell IDE Hoogle plugin";
437
437
+
license = stdenv.lib.licenses.bsd3;
438
438
+
}) { inherit ghc-mod; };
439
439
+
hie-plugin-api = callPackage
440
440
+
({ mkDerivation, aeson, base, containers, Diff, directory, either
441
441
+
, filepath, fingertree, ghc, ghc-mod-core, haskell-lsp, hie-base
442
442
+
, hslogger, lifted-base, monad-control, mtl, stdenv, stm, syb, text
443
443
+
, time, transformers, unordered-containers
444
444
+
}:
445
445
+
mkDerivation {
446
446
+
pname = "hie-plugin-api";
447
447
+
version = "0.1.0.0";
448
448
+
inherit src;
449
449
+
postUnpack = "sourceRoot=source/hie-plugin-api";
450
450
+
libraryHaskellDepends = [
451
451
+
aeson base containers Diff directory either filepath fingertree ghc
452
452
+
ghc-mod-core haskell-lsp hie-base hslogger lifted-base
453
453
+
monad-control mtl stm syb text time transformers
454
454
+
unordered-containers
455
455
+
];
456
456
+
description = "Haskell IDE API for plugin communication";
457
457
+
license = stdenv.lib.licenses.bsd3;
458
458
+
}) {};
459
459
+
}
+2
pkgs/development/haskell-modules/initial-packages.nix
reviewed
···
1
1
+
args@{ pkgs, stdenv, callPackage }: self:
2
2
+
(import ./hie-packages.nix args self) // (import ./hackage-packages.nix args self)
+40
pkgs/development/haskell-modules/patches/hie-testsuite.patch
reviewed
···
1
1
+
diff --git a/test/HaRePluginSpec.hs b/test/HaRePluginSpec.hs
2
2
+
index 039c094..d0d1fa4 100644
3
3
+
--- a/test/HaRePluginSpec.hs
4
4
+
+++ b/test/HaRePluginSpec.hs
5
5
+
@@ -326,35 +326,6 @@ hareSpec = do
6
6
+
$ List [TextEdit (Range (Position 4 0) (Position 8 12))
7
7
+
"parseStr = char '\"' *> (many1 (noneOf \"\\\"\")) <* char '\"'"])
8
8
+
Nothing)
9
9
+
- it "finds definition across components" $ do
10
10
+
- let u = filePathToUri "./app/Main.hs"
11
11
+
- let lreq = setTypecheckedModule u
12
12
+
- let req = findDef u (toPos (7,8))
13
13
+
- r <- dispatchRequestPGoto $ lreq >> req
14
14
+
- r `shouldBe` IdeResponseOk [Location (filePathToUri $ cwd </> "test/testdata/gototest/src/Lib.hs")
15
15
+
- (Range (toPos (6,1)) (toPos (6,9)))]
16
16
+
- let req2 = findDef u (toPos (7,20))
17
17
+
- r2 <- dispatchRequestPGoto $ lreq >> req2
18
18
+
- r2 `shouldBe` IdeResponseOk [Location (filePathToUri $ cwd </> "test/testdata/gototest/src/Lib2.hs")
19
19
+
- (Range (toPos (5,1)) (toPos (5,2)))]
20
20
+
- it "finds definition in the same component" $ do
21
21
+
- let u = filePathToUri "./src/Lib2.hs"
22
22
+
- let lreq = setTypecheckedModule u
23
23
+
- let req = findDef u (toPos (6,5))
24
24
+
- r <- dispatchRequestPGoto $ lreq >> req
25
25
+
- r `shouldBe` IdeResponseOk [Location (filePathToUri $ cwd </> "test/testdata/gototest/src/Lib.hs")
26
26
+
- (Range (toPos (6,1)) (toPos (6,9)))]
27
27
+
- it "finds local definitions" $ do
28
28
+
- let u = filePathToUri "./src/Lib2.hs"
29
29
+
- let lreq = setTypecheckedModule u
30
30
+
- let req = findDef u (toPos (7,11))
31
31
+
- r <- dispatchRequestPGoto $ lreq >> req
32
32
+
- r `shouldBe` IdeResponseOk [Location (filePathToUri $ cwd </> "test/testdata/gototest/src/Lib2.hs")
33
33
+
- (Range (toPos (10,9)) (toPos (10,10)))]
34
34
+
- let req2 = findDef u (toPos (10,13))
35
35
+
- r2 <- dispatchRequestPGoto $ lreq >> req2
36
36
+
- r2 `shouldBe` IdeResponseOk [Location (filePathToUri $ cwd </> "test/testdata/gototest/src/Lib2.hs")
37
37
+
- (Range (toPos (9,9)) (toPos (9,10)))]
38
38
+
39
39
+
40
40
+
-- ---------------------------------