-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdefault.nix
77 lines (74 loc) · 2.02 KB
/
default.nix
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
{ pkgs, mkDerivation }:
let
myPkgs =
let
hostPkgs = import <nixpkgs> {};
pinnedPkgs = hostPkgs.fetchFromGitHub {
owner = "NixOS";
repo = "nixpkgs";
# nixos-unstable as of 2017-11-13T08:53:10-00:00
rev = "b4372c4924d9182034066c823df76d6eaf1f4ec4";
sha256 = "TJv2srXt6fYPUjxgLAL0cy4nuf1OZD4KuA1TrCiQqg0=";
};
in
import pinnedPkgs {};
lib = myPkgs.haskell.lib;
nix-thunkSrc = pkgs.fetchFromGitHub {
owner = "obsidiansystems";
repo = "nix-thunk";
rev = "8fe6f2de2579ea3f17df2127f6b9f49db1be189f";
sha256 = "14l2k6wipam33696v3dr3chysxhqcy0j7hxfr10c0bxd1pxv7s8b";
};
nix-thunk = import nix-thunkSrc {};
webdriverSrc = nix-thunk.thunkSource ./deps/haskell-webdriver;
webdriver = myPkgs.haskellPackages.callCabal2nix "webdriver" webdriverSrc {};
haskellLib = pkgs.haskell.lib;
#webdriver = pkgs.haskellPackages.callHackage "webdriver" "0.10.0.0" {};
in
mkDerivation {
pname = "scrappy";
version = "0.1.0.4";
src = ./.;
libraryHaskellDepends =
with myPkgs.haskellPackages;
with myPkgs.haskell.lib;
[
aeson
bytestring
containers
directory
exceptions
http-client
http-client-tls
http-types
lens
modern-uri # less maintained?
mtl
network-uri
parsec
streaming-commons # required by http-client # TODO: try without, may just need zlib
time
text
transformers
(haskellLib.doJailbreak webdriver)
witherable
];
librarySystemDepends = [ myPkgs.nodejs pkgs.zlib pkgs.gmp ];
testHaskellDepends = with myPkgs.haskellPackages;
[
process
(haskellLib.doJailbreak webdriver)
process
which
transformers
parsec
text
exceptions
lifted-base
monad-control
random
];
homepage = "https://github.com/Ace-Interview-Prep/scrappy";
description = "html pattern matching library and high-level interface concurrent requests lib for webscraping";
license = lib.licenses.bsd3;
}