Commit 7abb9a14 authored by Alexandre Delanoë's avatar Alexandre Delanoë

Merge branch 'dev-doc-table-optimization' into dev

parents c52f2e37 704d818d
...@@ -3343,4 +3343,4 @@ ...@@ -3343,4 +3343,4 @@
"repo": "https://github.com/paf31/purescript-yargs.git", "repo": "https://github.com/paf31/purescript-yargs.git",
"version": "v4.0.0" "version": "v4.0.0"
} }
} }
\ No newline at end of file
{ pkgs ? import ./pinned.nix { } }:
import
(
pkgs.fetchFromGitHub {
owner = "justinwoo";
repo = "easy-purescript-nix";
rev = "14e7d85431e9f9838d7107d18cb79c7fa534f54e";
sha256 = "0lmkppidmhnayv0919990ifdd61f9d23dzjzr8amz7hjgc74yxs0";
}
) {
inherit pkgs;
}
#!/usr/bin/env nix-shell
#!nix-shell ./generate-packages-json.nix --run 'exit'
{ pkgs ? import ./pinned.nix { } }:
let
easy-dhall = import (
pkgs.fetchFromGitHub {
owner = "justinwoo";
repo = "easy-dhall-nix";
rev = "288ee825c326f352a5db194a024bd3e1f2f735b2";
sha256 = "12v4ql1nm1famz8r80k1xkkdgj7285vy2vn16iili0qwvz3i98ah";
}
) {
inherit pkgs;
};
in
pkgs.mkShell {
buildInputs = [ easy-dhall.dhall-simple easy-dhall.dhall-json-simple ];
shellHook = ''
dhall-to-json --file packages.dhall --output ./.psc-package/local/.set/packages.json
echo "generated packages.json"
'';
}
#!/usr/bin/env nix-shell
#!nix-shell ./generate-purs-packages.nix --run 'exit'
{ pkgs ? import ./pinned.nix { } }:
let
psc-package-nix = import ./psc-package-nix.nix { inherit pkgs; };
purs-project = import ./purs-project.nix { inherit pkgs; };
generatePursPackages = import "${psc-package-nix}/nix/generate-purs-packages.nix" {
inherit pkgs;
inherit (purs-project) packagesJson inputNames;
};
in
pkgs.mkShell {
buildInputs = [ generatePursPackages ];
shellHook = ''
generate-purs-packages > ./nix/purs-packages.nix
echo "generated purs-packages.nix"
'';
}
{ pkgs ? import ./pinned.nix { } }:
pkgs.fetchFromGitHub {
owner = "justinwoo";
repo = "psc-package-nix";
rev = "0f1f001e2ea17ad461871a1873050f6aef5f1284";
sha256 = "0gbwcvw8rvxhlg9p6avd0812y263jzim1sra5frbdi0s6q0ngsgi";
}
{ pkgs ? import <nixpkgs> {} }:
{
"aff" = {
name = "aff";
version = "v5.1.1";
src = pkgs.fetchgit {
url = "https://github.com/slamdata/purescript-aff.git";
rev = "v5.1.1";
sha256 = "19v5psd6jz13gr5yqyx8286b5bpfq1dax51w906y0mqgnfz92yzr";
};
};
"aff-promise" = {
name = "aff-promise";
version = "v2.1.0";
src = pkgs.fetchgit {
url = "https://github.com/nwolverson/purescript-aff-promise.git";
rev = "v2.1.0";
sha256 = "0khm53lvxgvc7fbsvcr2h2wlhcgay8vq45755f0w8vpk1441dvww";
};
};
"affjax" = {
name = "affjax";
version = "v9.0.0";
src = pkgs.fetchgit {
url = "https://github.com/slamdata/purescript-affjax.git";
rev = "v9.0.0";
sha256 = "04xij3q4802z58mzaaz661ifv1rd673fq2mjqj553dw326zplpvs";
};
};
"ansi" = {
name = "ansi";
version = "v5.0.0";
src = pkgs.fetchgit {
url = "https://github.com/hdgarrood/purescript-ansi.git";
rev = "v5.0.0";
sha256 = "16kgy9zbdms9appd69gad2bka44ijkcnc9p0kf5g7x672jypx3ar";
};
};
"argonaut" = {
name = "argonaut";
version = "v6.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-argonaut.git";
rev = "v6.0.0";
sha256 = "0b2jy5sf2lnn1r4kxnnm2vsr5iqkfas0jqp9yrrjmg7qngkd6qkw";
};
};
"argonaut-codecs" = {
name = "argonaut-codecs";
version = "v6.0.2";
src = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-argonaut-codecs.git";
rev = "v6.0.2";
sha256 = "1i8dm95kbcl7k92jqnylhng1rjcqx5z12yhf6mwvp0z0bmsz250b";
};
};
"argonaut-core" = {
name = "argonaut-core";
version = "v5.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-argonaut-core.git";
rev = "v5.0.0";
sha256 = "1d3jgyap3vwc7mc01ji6brmd2n8lr9mmgx0fl88yalrm2j89jrcc";
};
};
"argonaut-traversals" = {
name = "argonaut-traversals";
version = "v7.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-argonaut-traversals.git";
rev = "v7.0.0";
sha256 = "0mr6c7c64c5b7ia0b68vsjyjxw06ac9908xpgxdd969kpvcwq9x3";
};
};
"arraybuffer-types" = {
name = "arraybuffer-types";
version = "v2.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-arraybuffer-types.git";
rev = "v2.0.0";
sha256 = "059a8n49yhl46l1b1j2qj4ichzq6dzj29ajkfvw88npzj5w2rshy";
};
};
"arrays" = {
name = "arrays";
version = "v5.3.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-arrays.git";
rev = "v5.3.0";
sha256 = "0r991qcx69xj07iagjaxkm0ab9qi2pw8cs3qwyybhis7asd6bnz6";
};
};
"avar" = {
name = "avar";
version = "v3.0.0";
src = pkgs.fetchgit {
url = "https://github.com/slamdata/purescript-avar.git";
rev = "v3.0.0";
sha256 = "14g05jm2xricy5b9vn4k4lhc9lzi5jvpvv85h10s17kn4wwi9igk";
};
};
"bifunctors" = {
name = "bifunctors";
version = "v4.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-bifunctors.git";
rev = "v4.0.0";
sha256 = "1bdra5fbkraglqrrm484vw8h0wwk48kzkn586v4y7fg106q1q386";
};
};
"catenable-lists" = {
name = "catenable-lists";
version = "v5.0.1";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-catenable-lists.git";
rev = "v5.0.1";
sha256 = "0mbpb8xr9a7a4bvawhki7js5cbv7c0lv0vdwb6r8nmv6b61gzg27";
};
};
"colors" = {
name = "colors";
version = "v5.0.0";
src = pkgs.fetchgit {
url = "https://github.com/sharkdp/purescript-colors.git";
rev = "v5.0.0";
sha256 = "05bkfqllfpkh7nj0nzgd5p387hlpk0x35nam1i6xm3vzma9csj18";
};
};
"console" = {
name = "console";
version = "v4.2.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-console.git";
rev = "v4.2.0";
sha256 = "1b2nykdq1dzaqyra5pi8cvvz4dsbbkg57a2c88yi931ynm19nnw6";
};
};
"const" = {
name = "const";
version = "v4.1.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-const.git";
rev = "v4.1.0";
sha256 = "0qbd2aisax52yw6sybdhs7na943cbsd6mylhhgsamrf7hzh6v51p";
};
};
"contravariant" = {
name = "contravariant";
version = "v4.0.1";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-contravariant.git";
rev = "v4.0.1";
sha256 = "0dd17lwlybpz4i54cxnqdgy38rjlbw9p7bw1r43is6z3kdc8983a";
};
};
"control" = {
name = "control";
version = "v4.1.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-control.git";
rev = "v4.1.0";
sha256 = "10703zvsnjm5fc74k6wzjsvpsfyc3jci3jxhm7rxf7ymya9z1z53";
};
};
"coroutines" = {
name = "coroutines";
version = "v5.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-coroutines.git";
rev = "v5.0.0";
sha256 = "1jax7by8kn9fjg00avhziy3n18i3510iwzs3d73ziplanbw4qw4k";
};
};
"css" = {
name = "css";
version = "v4.0.0";
src = pkgs.fetchgit {
url = "https://github.com/slamdata/purescript-css.git";
rev = "v4.0.0";
sha256 = "0f6gib6rp20qz08vramw7k6kv2ck315lmshjpii8zmkjb5ya0w55";
};
};
"datetime" = {
name = "datetime";
version = "v4.1.1";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-datetime.git";
rev = "v4.1.1";
sha256 = "06ghfvbvd5sd0q014qi8j8glk2g2j9f8z8cwq2318kllp92gz07q";
};
};
"debug" = {
name = "debug";
version = "v4.0.0";
src = pkgs.fetchgit {
url = "https://github.com/garyb/purescript-debug.git";
rev = "v4.0.0";
sha256 = "0gwjj80akys0h111i74n429fmny992gx0r4rk1n98gqlqm5cmi21";
};
};
"distributive" = {
name = "distributive";
version = "v4.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-distributive.git";
rev = "v4.0.0";
sha256 = "0zbn0yq1vv7fbbf1lncg80irz0vg7wnw9b9wrzxhdzpbkw4jinsl";
};
};
"dom-filereader" = {
name = "dom-filereader";
version = "v5.0.0";
src = pkgs.fetchgit {
url = "https://github.com/nwolverson/purescript-dom-filereader";
rev = "v5.0.0";
sha256 = "0337r9qrnrgmfpssdvls5rz03y97kmxp2s8fr72i5hycih93yv74";
};
};
"dom-simple" = {
name = "dom-simple";
version = "v0.2.6";
src = pkgs.fetchgit {
url = "https://github.com/irresponsible/purescript-dom-simple";
rev = "v0.2.6";
sha256 = "0mdm4pz8ksjxpzj4s8gi979yrhyd4sj08zljp98s2qrsgd6a3rz7";
};
};
"effect" = {
name = "effect";
version = "v2.0.1";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-effect.git";
rev = "v2.0.1";
sha256 = "1vqw5wrdxzh1ww6z7271xr4kg4mx0r3k3mwg18dmgmzj11wbn2wh";
};
};
"either" = {
name = "either";
version = "v4.1.1";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-either.git";
rev = "v4.1.1";
sha256 = "12j7vvjly0bgxidxmb2pflx0zy7x425dnvxk2y1pm66n0hbsq7ns";
};
};
"enums" = {
name = "enums";
version = "v4.0.1";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-enums.git";
rev = "v4.0.1";
sha256 = "0qq0pgmq497nfml0y8xb2qdpga5xqp9sqq4ilv1rpyhg1v7nzb6v";
};
};
"exceptions" = {
name = "exceptions";
version = "v4.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-exceptions.git";
rev = "v4.0.0";
sha256 = "17s0rg9k4phivhx9j3l2vqqfdhk61gpj1xfqy8w6zj3rnxj0b2cv";
};
};
"exists" = {
name = "exists";
version = "v4.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-exists.git";
rev = "v4.0.0";
sha256 = "0bbdbw3jaqyi8dj2d52zvfgx4vl84d8cr6hp43vy8lfjfcbj0wlk";
};
};
"ffi-simple" = {
name = "ffi-simple";
version = "v0.2.4";
src = pkgs.fetchgit {
url = "https://github.com/irresponsible/purescript-ffi-simple";
rev = "v0.2.4";
sha256 = "1zrwrwqr71v0jb1m81hz9qxa33jkk0knry6f9qn8brjfjbs69lhy";
};
};
"foldable-traversable" = {
name = "foldable-traversable";
version = "v4.1.1";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-foldable-traversable.git";
rev = "v4.1.1";
sha256 = "03x89xcmphckzjlp4chc7swrpw347ll5bvr2yp7x9v2jqw2jlyi1";
};
};
"foreign" = {
name = "foreign";
version = "v5.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-foreign.git";
rev = "v5.0.0";
sha256 = "15mz2s4f8crkd721z4df2aag4s0wil6fs07cpcmi7dpnkn7a4nab";
};
};
"foreign-generic" = {
name = "foreign-generic";
version = "v10.0.0";
src = pkgs.fetchgit {
url = "https://github.com/paf31/purescript-foreign-generic.git";
rev = "v10.0.0";
sha256 = "1assvgmnim908plv7wzz4mrvq3lh4ayimgz5xk5njyz8p6pzkyvl";
};
};
"foreign-object" = {
name = "foreign-object";
version = "v2.0.3";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-foreign-object.git";
rev = "v2.0.3";
sha256 = "07wiql59zfj901nk9526b6rykn9m24jjcs8v5dgxbr1c3hiab9n3";
};
};
"fork" = {
name = "fork";
version = "v4.0.0";
src = pkgs.fetchgit {
url = "https://github.com/slamdata/purescript-fork.git";
rev = "v4.0.0";
sha256 = "1jygqzyci40c28gw2ygnx8v52hilhajj1bdpn7ndvss4i7yh1lcp";
};
};
"form-urlencoded" = {
name = "form-urlencoded";
version = "v4.0.1";
src = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-form-urlencoded.git";
rev = "v4.0.1";
sha256 = "14nb7mslmbms4wn4j6a7nrz8xmnach3qgcf8i1hgql1c8j7zkqz8";
};
};
"free" = {
name = "free";
version = "v5.2.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-free.git";
rev = "v5.2.0";
sha256 = "1bwj0ay7q9lm4ir29jy549m05jvaqik1s615biv23y51ngx3fn49";
};
};
"freet" = {
name = "freet";
version = "v4.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-freet.git";
rev = "v4.0.0";
sha256 = "1kpgggwimxjvdvhn6s7z4lzg3yw1rqg5f7pyamx9gh232s4va40i";
};
};
"functions" = {
name = "functions";
version = "v4.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-functions.git";
rev = "v4.0.0";
sha256 = "0675k5kxxwdvsjs6a3is8pwm3hmv0vbcza1b8ls10gymmfz3k3hj";
};
};
"functors" = {
name = "functors";
version = "v3.1.1";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-functors.git";
rev = "v3.1.1";
sha256 = "1cnn3zhk6qcyiwbbpvrdqgsbch4qihx2y9d6sv45bvd8kzrbd306";
};
};
"gen" = {
name = "gen";
version = "v2.1.1";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-gen.git";
rev = "v2.1.1";
sha256 = "0pk68cn1s89hql30ydks9gh34gbxg391smi2albx3qvxnfkrpxca";
};
};
"generics-rep" = {
name = "generics-rep";
version = "v6.1.1";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-generics-rep.git";
rev = "v6.1.1";
sha256 = "15vchzbcvf6byks90q14lvcwb8hnxqzm2mrlxi7v1f7has4s74kn";
};
};
"globals" = {
name = "globals";
version = "v4.1.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-globals";
rev = "v4.1.0";
sha256 = "03h4npdbsjr1mkjasdi071l0cl7zdf3l76a8f0x4ghx47yvpgadn";
};
};
"http-methods" = {
name = "http-methods";
version = "v4.0.2";
src = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-http-methods.git";
rev = "v4.0.2";
sha256 = "1wfgrlnl33bcqw54hbc8icah2fi0rvi5zxhz07665vy9p5ppvkqs";
};
};
"identity" = {
name = "identity";
version = "v4.1.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-identity.git";
rev = "v4.1.0";
sha256 = "1scdgbfkphfmapw7p9rnsiynpmqzyvnal2glzj450q51f8g1dhld";
};
};
"integers" = {
name = "integers";
version = "v4.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-integers.git";
rev = "v4.0.0";
sha256 = "17d4bfpnrmbxlc7hhhrvnli70ydaqyr26zgvc9q52a76zgdcb4cf";
};
};
"invariant" = {
name = "invariant";
version = "v4.1.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-invariant.git";
rev = "v4.1.0";
sha256 = "1fimpbh3yb7clvqxcdf4yf9im64z0v2s9pbspfacgq5b4vshjas9";
};
};
"js-date" = {
name = "js-date";
version = "v6.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-js-date.git";
rev = "v6.0.0";
sha256 = "19qyzbr4a1ca8znbd8gcbz0a801f5p1v238ky3408gdx4ba32zjd";
};
};
"js-timers" = {
name = "js-timers";
version = "v4.0.1";
src = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-js-timers.git";
rev = "v4.0.1";
sha256 = "1a8092sli7zqw1wflibhjza1ww21dxl7x7r602iazzwh2g70v4dg";
};
};
"lazy" = {
name = "lazy";
version = "v4.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-lazy.git";
rev = "v4.0.0";
sha256 = "156q89l4nvvn14imbhp6xvvm82q7kqh1pyndmldmnkhiqyr84vqv";
};
};
"lcg" = {
name = "lcg";
version = "v2.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-lcg.git";
rev = "v2.0.0";
sha256 = "1851cq2g84jzjbvbmncbivbhaqzj9zv5ni3gs14k04nmx2brxmvj";
};
};
"lists" = {
name = "lists";
version = "v5.4.1";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-lists.git";
rev = "v5.4.1";
sha256 = "0l0jiqhcjzkg4nv2a6h2vdf4izr9mf7cxc86cq1hf3j4dh6spym1";
};
};
"markdown" = {
name = "markdown";
version = "2020-03-04";
src = pkgs.fetchgit {
url = "https://github.com/poorscript/purescript-markdown";
rev = "2020-03-04";
sha256 = "0xp41wg1p4dwivgpy121mzpimkdakg0m83hx8ypb5ayjk98vvyf0";
};
};
"markdown-smolder" = {
name = "markdown-smolder";
version = "2020-03-04";
src = pkgs.fetchgit {
url = "https://github.com/poorscript/purescript-markdown-smolder";
rev = "2020-03-04";
sha256 = "1ls258cbmcv6sx516ppwwnxsrm6ydz3jm0q4lz83f57sryfa01b2";
};
};
"math" = {
name = "math";
version = "v2.1.1";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-math.git";
rev = "v2.1.1";
sha256 = "1msmy9w7y6fij62sdc55w68gpwkhm6lhgc8qjisjk4sxx1wdg1rr";
};
};
"maybe" = {
name = "maybe";
version = "v4.0.1";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-maybe.git";
rev = "v4.0.1";
sha256 = "073wa0d51daxdwacfcxg5pf6ch63n4ii55xm1ih87bxrg8mp52mx";
};
};
"media-types" = {
name = "media-types";
version = "v4.0.1";
src = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-media-types.git";
rev = "v4.0.1";
sha256 = "0ykwmxrhmwfy6c5mxjxa43xdf5xqakrqyvr5fn986yad50gjqj75";
};
};
"milkis" = {
name = "milkis";
version = "v7.2.0";
src = pkgs.fetchgit {
url = "https://github.com/justinwoo/purescript-milkis.git";
rev = "v7.2.0";
sha256 = "1i6l8k4clrnq4wxbdzzq08kagk591yr24xip86z1j7xap98y02xg";
};
};
"mmorph" = {
name = "mmorph";
version = "v5.1.0";
src = pkgs.fetchgit {
url = "https://github.com/Thimoteus/purescript-mmorph.git";
rev = "v5.1.0";
sha256 = "1lvdclqi9wzs4j8xj8ygnj2b87hhpbnl0c6m28zac05rz87s09mg";
};
};
"newtype" = {
name = "newtype";
version = "v3.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-newtype.git";
rev = "v3.0.0";
sha256 = "0qvk9p41miy806b05b4ikbr3if0fcyc35gfrwd2mflcxxp46011c";
};
};
"node-buffer" = {
name = "node-buffer";
version = "v5.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript-node/purescript-node-buffer.git";
rev = "v5.0.0";
sha256 = "0ih2y29srdxgn526fw2v1y95hpivjil44vkl93w6nrqsymki36y0";
};
};
"node-fs" = {
name = "node-fs";
version = "v5.0.1";
src = pkgs.fetchgit {
url = "https://github.com/purescript-node/purescript-node-fs.git";
rev = "v5.0.1";
sha256 = "0i3bd7aw16vyb5sh5fzlvgg9q6cjdvmnfs57in6rxm34z8d8c0p8";
};
};
"node-path" = {
name = "node-path";
version = "v3.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript-node/purescript-node-path.git";
rev = "v3.0.0";
sha256 = "0j1ni52m62dpcrfakl1ik131i31bkg91yv0p1c40sdw0f59fzf6x";
};
};
"node-streams" = {
name = "node-streams";
version = "v4.0.1";
src = pkgs.fetchgit {
url = "https://github.com/purescript-node/purescript-node-streams.git";
rev = "v4.0.1";
sha256 = "12dki2li0d7s54kvcr6gksb5nxf6kzs93gwxnq4bh1flri8p0i7r";
};
};
"nonempty" = {
name = "nonempty";
version = "v5.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-nonempty.git";
rev = "v5.0.0";
sha256 = "1vz174sg32cqrp52nwb2vz9frrzmdwzzlgl4vc2cm5wlf2anirxj";
};
};
"now" = {
name = "now";
version = "v4.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-now.git";
rev = "v4.0.0";
sha256 = "18h5pif2dy4r7w1xg2zw4mvdqlar9xqp3rawkiavmsc946ncf3zs";
};
};
"nullable" = {
name = "nullable";
version = "v4.1.1";
src = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-nullable.git";
rev = "v4.1.1";
sha256 = "14qaxxga8gqlr4pijyvqycdyhjr6qpz3h4aarficw5j75b7x8nyv";
};
};
"numbers" = {
name = "numbers";
version = "v7.0.0";
src = pkgs.fetchgit {
url = "https://github.com/sharkdp/purescript-numbers.git";
rev = "v7.0.0";
sha256 = "1l9s22fkjf7wc0zd3wjax4hlif7gqh6ij0ijb8sq20mfh2xl4hj8";
};
};
"ordered-collections" = {
name = "ordered-collections";
version = "v1.6.1";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-ordered-collections.git";
rev = "v1.6.1";
sha256 = "0r48p94d3cyzni2z7ikzcap472k23dx8zq37c1prmjb01v03mfvc";
};
};
"orders" = {
name = "orders";
version = "v4.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-orders.git";
rev = "v4.0.0";
sha256 = "13p1sm4dxkmxhld9x5qqg62iiajjb3qpzs66c1r24y5fs4zsfry4";
};
};
"parallel" = {
name = "parallel";
version = "v4.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-parallel.git";
rev = "v4.0.0";
sha256 = "1d5bnagabw2k8yxywkygwrpblb2ggqh2fhpqfrx2sj1y53x332hg";
};
};
"parsing" = {
name = "parsing";
version = "v5.0.3";
src = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-parsing.git";
rev = "v5.0.3";
sha256 = "0m5xvb5kis28laj3navyyakyq408vw115c2dvngf1vljzh1hk5kj";
};
};
"partial" = {
name = "partial";
version = "v2.0.1";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-partial.git";
rev = "v2.0.1";
sha256 = "11qr80989g7xmvw1brnrclsbg2wdkbr5k3cqpngfip3nnirrypcn";
};
};
"pipes" = {
name = "pipes";
version = "v6.0.0";
src = pkgs.fetchgit {
url = "https://github.com/felixSchl/purescript-pipes.git";
rev = "v6.0.0";
sha256 = "0vl37f42dy4w4hswiay22w0n14k7sr670x54iwn7428larzrzs8y";
};
};
"precise" = {
name = "precise";
version = "v4.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-precise";
rev = "v4.0.0";
sha256 = "18677n91h4dlfn07h7i6bwcngr6pp55w6nf4x6slq7v0n3a6xs5k";
};
};
"prelude" = {
name = "prelude";
version = "v4.1.1";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-prelude.git";
rev = "v4.1.1";
sha256 = "1frvjrv0mr508r6683l1mp5rzm1y2dz76fz40zf4k2c64sy6y1xm";
};
};
"profunctor" = {
name = "profunctor";
version = "v4.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-profunctor.git";
rev = "v4.0.0";
sha256 = "1v4kvmhmiwznd4lswp9339h64pgv5zvd3vm1q7gzj70767a3941i";
};
};
"profunctor-lenses" = {
name = "profunctor-lenses";
version = "v6.2.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-profunctor-lenses.git";
rev = "v6.2.0";
sha256 = "0bb8ib00in8d65kvympdlfncb7bp1qqsjvvpw9zfwiwf67ix4v57";
};
};
"proxy" = {
name = "proxy";
version = "v3.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-proxy.git";
rev = "v3.0.0";
sha256 = "0rqf25b1n9p5sgx7gdsxwrfv9rb3sqxgqmqpp5kdm30lfk7snz24";
};
};
"psci-support" = {
name = "psci-support";
version = "v4.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-psci-support.git";
rev = "v4.0.0";
sha256 = "0jd773zcklr6hjddqingzmk20a0afpm2r9pczfjbj0d93pbxb4xh";
};
};
"quickcheck" = {
name = "quickcheck";
version = "v6.1.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-quickcheck.git";
rev = "v6.1.0";
sha256 = "0b6208067krf81kzq2hbxs68386hcicbscwxbj5nck07ivjjvqh0";
};
};
"random" = {
name = "random";
version = "v4.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-random.git";
rev = "v4.0.0";
sha256 = "0k37v7z529adx6ypxj0xjyfrz45qia6p0vki2wpvi8lik7c698gf";
};
};
"react" = {
name = "react";
version = "v7.0.1";
src = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-react.git";
rev = "v7.0.1";
sha256 = "0kym675db8i4wzd0rh1f17k4mcfbf4pwnhpf7zhzkm9zaj7wc2cg";
};
};
"react-dom" = {
name = "react-dom";
version = "v6.1.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-react-dom.git";
rev = "v6.1.0";
sha256 = "19kzsahx3kvgbi9bhnnz50fjmqvvgslsg6rk028bj4v28m8gra40";
};
};
"reactix" = {
name = "reactix";
version = "v0.4.3";
src = pkgs.fetchgit {
url = "https://github.com/irresponsible/purescript-reactix";
rev = "v0.4.3";
sha256 = "0sg80qs7siswqvwfcsggjqvn9viqhxpkr452alyyslx5c3p2xamw";
};
};
"read" = {
name = "read";
version = "v1.0.1";
src = pkgs.fetchgit {
url = "https://github.com/truqu/purescript-read";
rev = "v1.0.1";
sha256 = "0q8c1xbwh781c1jngy04lbbaq44idy33klq7q1j5ax4vzgd54z0f";
};
};
"record" = {
name = "record";
version = "v2.0.1";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-record.git";
rev = "v2.0.1";
sha256 = "1l7ixb0gc2man36181g3hdf46sjp7xh0kv8bgrvalxfisjmd12v0";
};
};
"record-extra" = {
name = "record-extra";
version = "v3.0.0";
src = pkgs.fetchgit {
url = "https://github.com/justinwoo/purescript-record-extra.git";
rev = "v3.0.0";
sha256 = "1zhsgafd02h7161xldnf4z3sfjacp2if8py157igiszkjxaipvdd";
};
};
"refs" = {
name = "refs";
version = "v4.1.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-refs.git";
rev = "v4.1.0";
sha256 = "08161iy1xbafzblv033v84156azpcqkiw9v9d6gliphrq5fm17gm";
};
};
"routing" = {
name = "routing";
version = "v9.0.0";
src = pkgs.fetchgit {
url = "https://github.com/slamdata/purescript-routing.git";
rev = "v9.0.0";
sha256 = "1q05k1nrwpmlwy35fwa6kp1drk1ywnf5srmm1rzpliprvpli3is7";
};
};
"semirings" = {
name = "semirings";
version = "v5.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-semirings.git";
rev = "v5.0.0";
sha256 = "0bhrhn2yvcgil7g63spb2xw966mdhlk9mpspnqfijdpb9n3b79ds";
};
};
"sequences" = {
name = "sequences";
version = "v2.1.0";
src = pkgs.fetchgit {
url = "https://github.com/hdgarrood/purescript-sequences.git";
rev = "v2.1.0";
sha256 = "10fkkmmb7qh4p5gmgb6xpxh9g8hy06ddy8cyfrs3py8a5b8h46hw";
};
};
"smolder" = {
name = "smolder";
version = "v12.0.0";
src = pkgs.fetchgit {
url = "https://github.com/bodil/purescript-smolder.git";
rev = "v12.0.0";
sha256 = "1v8707hgm9g4k30afc30cxzfcz627bmxf7cn9wk3l3mh9ppl8kwd";
};
};
"spec" = {
name = "spec";
version = "v4.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript-spec/purescript-spec.git";
rev = "v4.0.0";
sha256 = "1b1hw3231ha5fq61948dfz28a0lm2mcn2pksszf7yw3137ysp5bn";
};
};
"spec-discovery" = {
name = "spec-discovery";
version = "v4.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript-spec/purescript-spec-discovery";
rev = "v4.0.0";
sha256 = "0kwc4nvy6rpbnhayang92h74fgyr28bh82pskwj7lm4sy513vhfw";
};
};
"spec-quickcheck" = {
name = "spec-quickcheck";
version = "v3.1.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript-spec/purescript-spec-quickcheck";
rev = "v3.1.0";
sha256 = "1l51v2j4z2cwdnf9hyx69jmlzlkk24l8gj38iphfspaiwyqwcmpg";
};
};
"st" = {
name = "st";
version = "v4.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-st.git";
rev = "v4.0.0";
sha256 = "0m2jkb9dmpbr8s1c20l7sm2q11y5rx8gqfiyspnyhq5apzkknjr0";
};
};
"string-parsers" = {
name = "string-parsers";
version = "v5.0.0";
src = pkgs.fetchgit {
url = "https://github.com/paf31/purescript-string-parsers.git";
rev = "v5.0.0";
sha256 = "1lykswyd3icv9lx4r096lxfd244i0pzj2f4fpm604czzlfw6bspv";
};
};
"strings" = {
name = "strings";
version = "v4.0.1";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-strings.git";
rev = "v4.0.1";
sha256 = "147l3l3fzn7liparhm2y3p8j4ck1lblra5j493p2hy5yy5ndznc8";
};
};
"stringutils" = {
name = "stringutils";
version = "v0.0.9";
src = pkgs.fetchgit {
url = "https://github.com/menelaos/purescript-stringutils.git";
rev = "v0.0.9";
sha256 = "00c679d5lk37gbfby2kasyq45rla6a0shg64zhyd2r4xrj0a74r4";
};
};
"tailrec" = {
name = "tailrec";
version = "v4.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-tailrec.git";
rev = "v4.0.0";
sha256 = "0z7k80nl8dgv8mc2w8xsl2n0637bd1l8ppxak8kaifgjjwa81hx3";
};
};
"thermite" = {
name = "thermite";
version = "hide-2020-03-04";
src = pkgs.fetchgit {
url = "https://github.com/poorscript/purescript-thermite.git";
rev = "hide-2020-03-04";
sha256 = "1s0fj6f7kqafiw027yw65f5193kph51x6dxw0wv3g6j77yxmk92i";
};
};
"these" = {
name = "these";
version = "v4.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-these.git";
rev = "v4.0.0";
sha256 = "0ywwpbcz1d0pdi3f9h9kla52vq1if8zwdz7jq7lqz5s8zj8kyg5r";
};
};
"transformers" = {
name = "transformers";
version = "v4.2.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-transformers.git";
rev = "v4.2.0";
sha256 = "03qmvl9s7lbvm73dy9ps6qp39pdcm91hb8yakgj7aq8hgpj7b6bg";
};
};
"tuples" = {
name = "tuples";
version = "v5.1.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-tuples.git";
rev = "v5.1.0";
sha256 = "045nsy0r2g51gih0wjhcvhl6gfr8947mlrqwg644ygz72rjm8wq4";
};
};
"tuples-native" = {
name = "tuples-native";
version = "v2.0.1";
src = pkgs.fetchgit {
url = "https://github.com/athanclark/purescript-tuples-native";
rev = "v2.0.1";
sha256 = "1c8065krignnphiwnws9d5ingfx8k83wqnmd1zadyjlakfdg2b4h";
};
};
"type-equality" = {
name = "type-equality";
version = "v3.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-type-equality.git";
rev = "v3.0.0";
sha256 = "1b7szyca5s96gaawvgwrw7fa8r7gqsdff7xhz3vvngnylv2scl3w";
};
};
"typelevel" = {
name = "typelevel";
version = "v5.0.0";
src = pkgs.fetchgit {
url = "https://github.com/bodil/purescript-typelevel.git";
rev = "v5.0.0";
sha256 = "1s0fdffmn386hahv670fc5vvj0x0cqk64i4jj95rfavffch4x7va";
};
};
"typelevel-prelude" = {
name = "typelevel-prelude";
version = "v5.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-typelevel-prelude.git";
rev = "v5.0.0";
sha256 = "01ki39xj87kwf8j8divlzwrvfyjcgxpmzhhmxzjylqx6jarcwyg6";
};
};
"uint" = {
name = "uint";
version = "v5.1.1";
src = pkgs.fetchgit {
url = "https://github.com/zaquest/purescript-uint";
rev = "v5.1.1";
sha256 = "13103kqj2abiy8p7v81w1dj8jm0mll177mfjb7ar6km0bsxjigc6";
};
};
"unfoldable" = {
name = "unfoldable";
version = "v4.0.2";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-unfoldable.git";
rev = "v4.0.2";
sha256 = "0lzhx030c5933maxcjwk6kzlvbxky1kiwrymqf1dp5wbrar3jyv4";
};
};
"unicode" = {
name = "unicode";
version = "v4.0.1";
src = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-unicode.git";
rev = "v4.0.1";
sha256 = "1a53jv7pzyjk5v6kmwwy50d3l8d26k0id59sn8g3lzkih24nalhp";
};
};
"unsafe-coerce" = {
name = "unsafe-coerce";
version = "v4.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-unsafe-coerce.git";
rev = "v4.0.0";
sha256 = "0k9255mk2mz6xjb11pwkgfcblmmyvr86ig5kr92jwy95xim09zip";
};
};
"uri" = {
name = "uri";
version = "v7.0.0";
src = pkgs.fetchgit {
url = "https://github.com/slamdata/purescript-uri";
rev = "v7.0.0";
sha256 = "1ry5h5656k2hn3y5s35y7pz0rngbkvj9jc783i4h9ai3hndi00py";
};
};
"validation" = {
name = "validation";
version = "v4.2.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-validation.git";
rev = "v4.2.0";
sha256 = "03irk6n7jgsimhp9ckrg2ns7qbc8d383ls3sslxgir5mr8xdc44g";
};
};
"versions" = {
name = "versions";
version = "v5.0.1";
src = pkgs.fetchgit {
url = "https://github.com/hdgarrood/purescript-versions.git";
rev = "v5.0.1";
sha256 = "07h2s3411w9d0iany7arw01qvfj57wgj8pgfqvrm0vvvhhc0v9f6";
};
};
"web-dom" = {
name = "web-dom";
version = "v3.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript-web/purescript-web-dom.git";
rev = "v3.0.0";
sha256 = "14mssfhg81diy82wbv3ja8zk9a92267c6svq4bgfag91hydw4p42";
};
};
"web-events" = {
name = "web-events";
version = "v2.0.1";
src = pkgs.fetchgit {
url = "https://github.com/purescript-web/purescript-web-events.git";
rev = "v2.0.1";
sha256 = "1vd1gfh6zv50bq4v1ppl2wvc5mskcw9n1bfj29qjg0dx0ffxzv2f";
};
};
"web-file" = {
name = "web-file";
version = "v2.1.1";
src = pkgs.fetchgit {
url = "https://github.com/purescript-web/purescript-web-file.git";
rev = "v2.1.1";
sha256 = "08k0xv9zpg040v32k3wk66bhzx16c2nn9v35f01gq96anhm713s1";
};
};
"web-html" = {
name = "web-html";
version = "v2.2.1";
src = pkgs.fetchgit {
url = "https://github.com/purescript-web/purescript-web-html.git";
rev = "v2.2.1";
sha256 = "026y4kkrc2z4zmxlc4z21znq8knaqqjazf1ny811gm1507b1ykc6";
};
};
"web-storage" = {
name = "web-storage";
version = "v3.0.0";
src = pkgs.fetchgit {
url = "https://github.com/purescript-web/purescript-web-storage.git";
rev = "v3.0.0";
sha256 = "1ycb2s29aw9w6lqik6hfmp9nf9i2yhn0q26hc4p3450jam5mj8bx";
};
};
"web-xhr" = {
name = "web-xhr";
version = "v3.0.1";
src = pkgs.fetchgit {
url = "https://github.com/purescript-web/purescript-web-xhr.git";
rev = "v3.0.1";
sha256 = "1217lmvla3rqd9kzvvjxpngj7nxjn2ianm9xhlc0iydzsd0agihi";
};
};
}
#!/usr/bin/env nix-shell
{ pkgs ? import ./pinned.nix { } }:
let
packagesJson = ../.psc-package/local/.set/packages.json;
inputNames = (pkgs.lib.importJSON ../psc-package.json).depends;
pursPackages = import ./purs-packages.nix { inherit pkgs; };
getUnquotedSourceGlob = x: ''${x.src}/src/**/*.purs'';
unquotedSourceGlobs = map getUnquotedSourceGlob (builtins.attrValues pursPackages);
quote = x: ''"${x}"'';
sourceGlobs = map quote unquotedSourceGlobs;
in
{
inherit packagesJson inputNames sourceGlobs unquotedSourceGlobs;
}
...@@ -4,6 +4,7 @@ ...@@ -4,6 +4,7 @@
"source": ".psc-package/local/.set/packages.json", "source": ".psc-package/local/.set/packages.json",
"depends": [ "depends": [
"affjax", "affjax",
"aff-promise",
"argonaut", "argonaut",
"console", "console",
"css", "css",
...@@ -20,6 +21,7 @@ ...@@ -20,6 +21,7 @@
"markdown-smolder", "markdown-smolder",
"math", "math",
"maybe", "maybe",
"milkis",
"nonempty", "nonempty",
"numbers", "numbers",
"prelude", "prelude",
......
#Generated by soba https://github.com/justinwoo/soba
{ pkgs ? import <nixpkgs> {} }:
{
"aff" = pkgs.stdenv.mkDerivation {
name = "aff";
version = "v5.1.1";
fetched = pkgs.fetchgit {
url = "https://github.com/slamdata/purescript-aff.git";
rev = "390857f9143e1a52f7403d05b14c9ca79d356737";
sha256 = "19v5psd6jz13gr5yqyx8286b5bpfq1dax51w906y0mqgnfz92yzr";
};
};
"affjax" = pkgs.stdenv.mkDerivation {
name = "affjax";
version = "v9.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/slamdata/purescript-affjax.git";
rev = "ec9c50e35980ba33b4bc7a3bc026970ba27bf767";
sha256 = "04xij3q4802z58mzaaz661ifv1rd673fq2mjqj553dw326zplpvs";
};
};
"ansi" = pkgs.stdenv.mkDerivation {
name = "ansi";
version = "v5.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/hdgarrood/purescript-ansi.git";
rev = "e060b4a7c9a0df9359871cb0c5773139e5525d2f";
sha256 = "16kgy9zbdms9appd69gad2bka44ijkcnc9p0kf5g7x672jypx3ar";
};
};
"argonaut" = pkgs.stdenv.mkDerivation {
name = "argonaut";
version = "v6.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-argonaut.git";
rev = "3365736b862ec6d8948ea31debebd04d0abf12fc";
sha256 = "0b2jy5sf2lnn1r4kxnnm2vsr5iqkfas0jqp9yrrjmg7qngkd6qkw";
};
};
"argonaut-codecs" = pkgs.stdenv.mkDerivation {
name = "argonaut-codecs";
version = "v6.0.2";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-argonaut-codecs.git";
rev = "b0317d576e10aa73600c43f835bfad45679d0aff";
sha256 = "1i8dm95kbcl7k92jqnylhng1rjcqx5z12yhf6mwvp0z0bmsz250b";
};
};
"argonaut-core" = pkgs.stdenv.mkDerivation {
name = "argonaut-core";
version = "v5.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-argonaut-core.git";
rev = "bebd7099b9cd681659dcd93407e639219360188e";
sha256 = "1d3jgyap3vwc7mc01ji6brmd2n8lr9mmgx0fl88yalrm2j89jrcc";
};
};
"argonaut-traversals" = pkgs.stdenv.mkDerivation {
name = "argonaut-traversals";
version = "v7.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-argonaut-traversals.git";
rev = "6613254947961686341eaa1ed23886c9d2587d93";
sha256 = "0mr6c7c64c5b7ia0b68vsjyjxw06ac9908xpgxdd969kpvcwq9x3";
};
};
"arraybuffer-types" = pkgs.stdenv.mkDerivation {
name = "arraybuffer-types";
version = "v2.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-arraybuffer-types.git";
rev = "505aa3de50a1400e5f2fce4a8e7b1a39abaa8fd9";
sha256 = "059a8n49yhl46l1b1j2qj4ichzq6dzj29ajkfvw88npzj5w2rshy";
};
};
"arrays" = pkgs.stdenv.mkDerivation {
name = "arrays";
version = "v5.3.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-arrays.git";
rev = "1bca4c0b8904e65d356ed6d8db8d6f7e071132d3";
sha256 = "0r991qcx69xj07iagjaxkm0ab9qi2pw8cs3qwyybhis7asd6bnz6";
};
};
"avar" = pkgs.stdenv.mkDerivation {
name = "avar";
version = "v3.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/slamdata/purescript-avar.git";
rev = "17914413130490318a475e9de6a9244aaaa097d2";
sha256 = "14g05jm2xricy5b9vn4k4lhc9lzi5jvpvv85h10s17kn4wwi9igk";
};
};
"bifunctors" = pkgs.stdenv.mkDerivation {
name = "bifunctors";
version = "v4.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-bifunctors.git";
rev = "1062425892b4a1c734ec653dded22546e3063b27";
sha256 = "1bdra5fbkraglqrrm484vw8h0wwk48kzkn586v4y7fg106q1q386";
};
};
"catenable-lists" = pkgs.stdenv.mkDerivation {
name = "catenable-lists";
version = "v5.0.1";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-catenable-lists.git";
rev = "d81b7df30d9879d0bb531b3102fb36f429c2f12e";
sha256 = "0mbpb8xr9a7a4bvawhki7js5cbv7c0lv0vdwb6r8nmv6b61gzg27";
};
};
"colors" = pkgs.stdenv.mkDerivation {
name = "colors";
version = "v5.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/sharkdp/purescript-colors.git";
rev = "fb582d3626e566371d20d4ef0b8d2795ee80f024";
sha256 = "05bkfqllfpkh7nj0nzgd5p387hlpk0x35nam1i6xm3vzma9csj18";
};
};
"console" = pkgs.stdenv.mkDerivation {
name = "console";
version = "v4.2.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-console.git";
rev = "add2bdb8a4af2213d993b728805f1f2a5e76deb8";
sha256 = "1b2nykdq1dzaqyra5pi8cvvz4dsbbkg57a2c88yi931ynm19nnw6";
};
};
"const" = pkgs.stdenv.mkDerivation {
name = "const";
version = "v4.1.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-const.git";
rev = "bc5db27b0ed3947fa5e2074ccbab01236eec3fa4";
sha256 = "0qbd2aisax52yw6sybdhs7na943cbsd6mylhhgsamrf7hzh6v51p";
};
};
"contravariant" = pkgs.stdenv.mkDerivation {
name = "contravariant";
version = "v4.0.1";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-contravariant.git";
rev = "cb69db0253c2e2ed3fef784dad58f3418a8ee834";
sha256 = "0dd17lwlybpz4i54cxnqdgy38rjlbw9p7bw1r43is6z3kdc8983a";
};
};
"control" = pkgs.stdenv.mkDerivation {
name = "control";
version = "v4.1.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-control.git";
rev = "8af53eea4ecc7b185776a0f144bcd7106ed08eb1";
sha256 = "10703zvsnjm5fc74k6wzjsvpsfyc3jci3jxhm7rxf7ymya9z1z53";
};
};
"coroutines" = pkgs.stdenv.mkDerivation {
name = "coroutines";
version = "v5.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-coroutines.git";
rev = "6f5750d1b200d6bb405f681f974887508b82b4d2";
sha256 = "1jax7by8kn9fjg00avhziy3n18i3510iwzs3d73ziplanbw4qw4k";
};
};
"css" = pkgs.stdenv.mkDerivation {
name = "css";
version = "v4.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/slamdata/purescript-css.git";
rev = "0164325e66dd59b3b5a4ea53ac8adf7d389b4c8e";
sha256 = "0f6gib6rp20qz08vramw7k6kv2ck315lmshjpii8zmkjb5ya0w55";
};
};
"datetime" = pkgs.stdenv.mkDerivation {
name = "datetime";
version = "v4.1.1";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-datetime.git";
rev = "9e76abe96f45a68eb0bb23d0afd56031a8070bee";
sha256 = "06ghfvbvd5sd0q014qi8j8glk2g2j9f8z8cwq2318kllp92gz07q";
};
};
"debug" = pkgs.stdenv.mkDerivation {
name = "debug";
version = "v4.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/garyb/purescript-debug.git";
rev = "b1484b8aac685dc83c1d938d71407495ae2a2259";
sha256 = "0gwjj80akys0h111i74n429fmny992gx0r4rk1n98gqlqm5cmi21";
};
};
"distributive" = pkgs.stdenv.mkDerivation {
name = "distributive";
version = "v4.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-distributive.git";
rev = "3a43c0690883816e9ebeac510698423cfff5c174";
sha256 = "0zbn0yq1vv7fbbf1lncg80irz0vg7wnw9b9wrzxhdzpbkw4jinsl";
};
};
"dom-filereader" = pkgs.stdenv.mkDerivation {
name = "dom-filereader";
version = "v5.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/nwolverson/purescript-dom-filereader";
rev = "14ef7eb23c7b90113c3a9d0e745359a6efecbff1";
sha256 = "0337r9qrnrgmfpssdvls5rz03y97kmxp2s8fr72i5hycih93yv74";
};
};
"dom-simple" = pkgs.stdenv.mkDerivation {
name = "dom-simple";
version = "v0.2.6";
fetched = pkgs.fetchgit {
url = "https://github.com/irresponsible/purescript-dom-simple";
rev = "806688c06a5ae71228f89648c63d47436f7b9220";
sha256 = "0mdm4pz8ksjxpzj4s8gi979yrhyd4sj08zljp98s2qrsgd6a3rz7";
};
};
"effect" = pkgs.stdenv.mkDerivation {
name = "effect";
version = "v2.0.1";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-effect.git";
rev = "6caa8e1e162a21eed025613c2c19194b996ef779";
sha256 = "1vqw5wrdxzh1ww6z7271xr4kg4mx0r3k3mwg18dmgmzj11wbn2wh";
};
};
"either" = pkgs.stdenv.mkDerivation {
name = "either";
version = "v4.1.1";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-either.git";
rev = "8b4b38a729f8e88750b03e5c7baf2b3863ce4742";
sha256 = "12j7vvjly0bgxidxmb2pflx0zy7x425dnvxk2y1pm66n0hbsq7ns";
};
};
"enums" = pkgs.stdenv.mkDerivation {
name = "enums";
version = "v4.0.1";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-enums.git";
rev = "19800105b556798ea5650f8a01bfe5ea17cfc6eb";
sha256 = "0qq0pgmq497nfml0y8xb2qdpga5xqp9sqq4ilv1rpyhg1v7nzb6v";
};
};
"exceptions" = pkgs.stdenv.mkDerivation {
name = "exceptions";
version = "v4.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-exceptions.git";
rev = "9012eb08749e9ccd5da45bdece5d576e5fc0b0db";
sha256 = "17s0rg9k4phivhx9j3l2vqqfdhk61gpj1xfqy8w6zj3rnxj0b2cv";
};
};
"exists" = pkgs.stdenv.mkDerivation {
name = "exists";
version = "v4.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-exists.git";
rev = "ef53359aebc09bf863800ca86ad1dcd76f0b08ae";
sha256 = "0bbdbw3jaqyi8dj2d52zvfgx4vl84d8cr6hp43vy8lfjfcbj0wlk";
};
};
"ffi-simple" = pkgs.stdenv.mkDerivation {
name = "ffi-simple";
version = "v0.2.4";
fetched = pkgs.fetchgit {
url = "https://github.com/irresponsible/purescript-ffi-simple";
rev = "1648e033abbbcf5952cbad1462776b0e24019595";
sha256 = "1zrwrwqr71v0jb1m81hz9qxa33jkk0knry6f9qn8brjfjbs69lhy";
};
};
"foldable-traversable" = pkgs.stdenv.mkDerivation {
name = "foldable-traversable";
version = "v4.1.1";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-foldable-traversable.git";
rev = "29d5b873cc86f17e0082d777629819a96bdbc7a1";
sha256 = "03x89xcmphckzjlp4chc7swrpw347ll5bvr2yp7x9v2jqw2jlyi1";
};
};
"foreign" = pkgs.stdenv.mkDerivation {
name = "foreign";
version = "v5.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-foreign.git";
rev = "3b8f3ae608db339ed5cff35d2017a07efb905b4d";
sha256 = "15mz2s4f8crkd721z4df2aag4s0wil6fs07cpcmi7dpnkn7a4nab";
};
};
"foreign-generic" = pkgs.stdenv.mkDerivation {
name = "foreign-generic";
version = "v10.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/paf31/purescript-foreign-generic.git";
rev = "46f09996bd54efc146bc1725783789dbac7d6a5b";
sha256 = "1assvgmnim908plv7wzz4mrvq3lh4ayimgz5xk5njyz8p6pzkyvl";
};
};
"foreign-object" = pkgs.stdenv.mkDerivation {
name = "foreign-object";
version = "v2.0.3";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-foreign-object.git";
rev = "8a7dc21c48e3e6d31e253b0e58dd95a3bbd7f6e7";
sha256 = "07wiql59zfj901nk9526b6rykn9m24jjcs8v5dgxbr1c3hiab9n3";
};
};
"fork" = pkgs.stdenv.mkDerivation {
name = "fork";
version = "v4.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/slamdata/purescript-fork.git";
rev = "27b9f223645a08b42731531a154892eaa263b590";
sha256 = "1jygqzyci40c28gw2ygnx8v52hilhajj1bdpn7ndvss4i7yh1lcp";
};
};
"form-urlencoded" = pkgs.stdenv.mkDerivation {
name = "form-urlencoded";
version = "v4.0.1";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-form-urlencoded.git";
rev = "36df7951f69a62f7dcf545787734420f4a8bf83a";
sha256 = "14nb7mslmbms4wn4j6a7nrz8xmnach3qgcf8i1hgql1c8j7zkqz8";
};
};
"free" = pkgs.stdenv.mkDerivation {
name = "free";
version = "v5.2.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-free.git";
rev = "f686f5fc07766f3ca9abc83b47b6ad3da326759a";
sha256 = "1bwj0ay7q9lm4ir29jy549m05jvaqik1s615biv23y51ngx3fn49";
};
};
"freet" = pkgs.stdenv.mkDerivation {
name = "freet";
version = "v4.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-freet.git";
rev = "8b9cee0a143ec965eaa6e2d9ccfd24fd1f129bd7";
sha256 = "1kpgggwimxjvdvhn6s7z4lzg3yw1rqg5f7pyamx9gh232s4va40i";
};
};
"functions" = pkgs.stdenv.mkDerivation {
name = "functions";
version = "v4.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-functions.git";
rev = "c63451ae74f6fba7a4eede5f87208a73c537af77";
sha256 = "0675k5kxxwdvsjs6a3is8pwm3hmv0vbcza1b8ls10gymmfz3k3hj";
};
};
"functors" = pkgs.stdenv.mkDerivation {
name = "functors";
version = "v3.1.1";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-functors.git";
rev = "96bcf8a970a40115a76a20d19e50aa3b524adcf3";
sha256 = "1cnn3zhk6qcyiwbbpvrdqgsbch4qihx2y9d6sv45bvd8kzrbd306";
};
};
"gen" = pkgs.stdenv.mkDerivation {
name = "gen";
version = "v2.1.1";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-gen.git";
rev = "36f36f03f082b57e402c27f1513f8935caa54101";
sha256 = "0pk68cn1s89hql30ydks9gh34gbxg391smi2albx3qvxnfkrpxca";
};
};
"generics-rep" = pkgs.stdenv.mkDerivation {
name = "generics-rep";
version = "v6.1.1";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-generics-rep.git";
rev = "aae27ba1de21dda342dcdfc8b3cc5b951bd5b3ec";
sha256 = "15vchzbcvf6byks90q14lvcwb8hnxqzm2mrlxi7v1f7has4s74kn";
};
};
"globals" = pkgs.stdenv.mkDerivation {
name = "globals";
version = "v4.1.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-globals";
rev = "8e6d69c36b6fd8c988a3664fc033ad11dbdd5860";
sha256 = "03h4npdbsjr1mkjasdi071l0cl7zdf3l76a8f0x4ghx47yvpgadn";
};
};
"http-methods" = pkgs.stdenv.mkDerivation {
name = "http-methods";
version = "v4.0.2";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-http-methods.git";
rev = "f3672edd166d323849b9dfd1e01c6eeb978fd56c";
sha256 = "1wfgrlnl33bcqw54hbc8icah2fi0rvi5zxhz07665vy9p5ppvkqs";
};
};
"identity" = pkgs.stdenv.mkDerivation {
name = "identity";
version = "v4.1.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-identity.git";
rev = "1b7938abdc8cb28c0ac5f80f63405d53e3173a8e";
sha256 = "1scdgbfkphfmapw7p9rnsiynpmqzyvnal2glzj450q51f8g1dhld";
};
};
"integers" = pkgs.stdenv.mkDerivation {
name = "integers";
version = "v4.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-integers.git";
rev = "3850da9cd96b37c71685b6bc3bf0cb489baefc93";
sha256 = "17d4bfpnrmbxlc7hhhrvnli70ydaqyr26zgvc9q52a76zgdcb4cf";
};
};
"invariant" = pkgs.stdenv.mkDerivation {
name = "invariant";
version = "v4.1.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-invariant.git";
rev = "b704c5bda262719ca5cc88a3f8554edff8f03256";
sha256 = "1fimpbh3yb7clvqxcdf4yf9im64z0v2s9pbspfacgq5b4vshjas9";
};
};
"js-date" = pkgs.stdenv.mkDerivation {
name = "js-date";
version = "v6.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-js-date.git";
rev = "f332c15f14322434ddd1945ca2db8040294447bf";
sha256 = "19qyzbr4a1ca8znbd8gcbz0a801f5p1v238ky3408gdx4ba32zjd";
};
};
"js-timers" = pkgs.stdenv.mkDerivation {
name = "js-timers";
version = "v4.0.1";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-js-timers.git";
rev = "8206d3d8034357b4665828e52f7ff1b8cb46611e";
sha256 = "1a8092sli7zqw1wflibhjza1ww21dxl7x7r602iazzwh2g70v4dg";
};
};
"lazy" = pkgs.stdenv.mkDerivation {
name = "lazy";
version = "v4.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-lazy.git";
rev = "5bbd04f507a704f39aa756b5e12ed6665205fe2e";
sha256 = "156q89l4nvvn14imbhp6xvvm82q7kqh1pyndmldmnkhiqyr84vqv";
};
};
"lcg" = pkgs.stdenv.mkDerivation {
name = "lcg";
version = "v2.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-lcg.git";
rev = "596bcb17bd550397735220f919df52bcd0038fe0";
sha256 = "1851cq2g84jzjbvbmncbivbhaqzj9zv5ni3gs14k04nmx2brxmvj";
};
};
"lists" = pkgs.stdenv.mkDerivation {
name = "lists";
version = "v5.4.1";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-lists.git";
rev = "62900a56f6864638c952575dfd211a1cc55be7da";
sha256 = "0l0jiqhcjzkg4nv2a6h2vdf4izr9mf7cxc86cq1hf3j4dh6spym1";
};
};
"markdown" = pkgs.stdenv.mkDerivation {
name = "markdown";
version = "2020-03-04";
fetched = pkgs.fetchgit {
url = "https://github.com/poorscript/purescript-markdown";
rev = "b51ee0e4aa04c9e6a5a70f2552a400c3f9cad439";
sha256 = "0xp41wg1p4dwivgpy121mzpimkdakg0m83hx8ypb5ayjk98vvyf0";
};
};
"markdown-smolder" = pkgs.stdenv.mkDerivation {
name = "markdown-smolder";
version = "2020-03-04";
fetched = pkgs.fetchgit {
url = "https://github.com/poorscript/purescript-markdown-smolder";
rev = "0abad68dae30af019476ec5a41420e03a3093f7e";
sha256 = "1ls258cbmcv6sx516ppwwnxsrm6ydz3jm0q4lz83f57sryfa01b2";
};
};
"math" = pkgs.stdenv.mkDerivation {
name = "math";
version = "v2.1.1";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-math.git";
rev = "8be36d24f9d2d8795adf04791446bbc458297b9b";
sha256 = "1msmy9w7y6fij62sdc55w68gpwkhm6lhgc8qjisjk4sxx1wdg1rr";
};
};
"maybe" = pkgs.stdenv.mkDerivation {
name = "maybe";
version = "v4.0.1";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-maybe.git";
rev = "81f0397636bcbca28642f62421aebfd9e1afa7fb";
sha256 = "073wa0d51daxdwacfcxg5pf6ch63n4ii55xm1ih87bxrg8mp52mx";
};
};
"media-types" = pkgs.stdenv.mkDerivation {
name = "media-types";
version = "v4.0.1";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-media-types.git";
rev = "e304498356539547b4ed9a7f79513a847c907962";
sha256 = "0ykwmxrhmwfy6c5mxjxa43xdf5xqakrqyvr5fn986yad50gjqj75";
};
};
"mmorph" = pkgs.stdenv.mkDerivation {
name = "mmorph";
version = "v5.1.0";
fetched = pkgs.fetchgit {
url = "https://github.com/Thimoteus/purescript-mmorph.git";
rev = "e067ee63c9c08e67b632a8b55930f744ddfad980";
sha256 = "1lvdclqi9wzs4j8xj8ygnj2b87hhpbnl0c6m28zac05rz87s09mg";
};
};
"newtype" = pkgs.stdenv.mkDerivation {
name = "newtype";
version = "v3.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-newtype.git";
rev = "7d85fa6a040208c010b05f7c23af6a943ba08763";
sha256 = "0qvk9p41miy806b05b4ikbr3if0fcyc35gfrwd2mflcxxp46011c";
};
};
"node-buffer" = pkgs.stdenv.mkDerivation {
name = "node-buffer";
version = "v5.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript-node/purescript-node-buffer.git";
rev = "d279daa1b4bf9fe85d5c3aeb96512df4f12e0bc0";
sha256 = "0ih2y29srdxgn526fw2v1y95hpivjil44vkl93w6nrqsymki36y0";
};
};
"node-fs" = pkgs.stdenv.mkDerivation {
name = "node-fs";
version = "v5.0.1";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript-node/purescript-node-fs.git";
rev = "02d610f237dc130edb5ee594fd46b16c691b79eb";
sha256 = "0i3bd7aw16vyb5sh5fzlvgg9q6cjdvmnfs57in6rxm34z8d8c0p8";
};
};
"node-path" = pkgs.stdenv.mkDerivation {
name = "node-path";
version = "v3.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript-node/purescript-node-path.git";
rev = "e3a704d5fc7d25fa93c6cd0eb92dbce9e5ebd69a";
sha256 = "0j1ni52m62dpcrfakl1ik131i31bkg91yv0p1c40sdw0f59fzf6x";
};
};
"node-streams" = pkgs.stdenv.mkDerivation {
name = "node-streams";
version = "v4.0.1";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript-node/purescript-node-streams.git";
rev = "88740eeda2017d3ddcde50eea59d57c7749d8524";
sha256 = "12dki2li0d7s54kvcr6gksb5nxf6kzs93gwxnq4bh1flri8p0i7r";
};
};
"nonempty" = pkgs.stdenv.mkDerivation {
name = "nonempty";
version = "v5.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-nonempty.git";
rev = "36ca3b2fa6d98b1c9d2ee05643341e496fbeab57";
sha256 = "1vz174sg32cqrp52nwb2vz9frrzmdwzzlgl4vc2cm5wlf2anirxj";
};
};
"now" = pkgs.stdenv.mkDerivation {
name = "now";
version = "v4.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-now.git";
rev = "090feddf7c7dec2a812eca090cd211e87ccad606";
sha256 = "18h5pif2dy4r7w1xg2zw4mvdqlar9xqp3rawkiavmsc946ncf3zs";
};
};
"nullable" = pkgs.stdenv.mkDerivation {
name = "nullable";
version = "v4.1.1";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-nullable.git";
rev = "8d413f02224b8281bfa8037e45fbbf9fe2e254fd";
sha256 = "14qaxxga8gqlr4pijyvqycdyhjr6qpz3h4aarficw5j75b7x8nyv";
};
};
"numbers" = pkgs.stdenv.mkDerivation {
name = "numbers";
version = "v7.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/sharkdp/purescript-numbers.git";
rev = "6262a5f17dcdfba11dfae03f4fa8eec02f7ed29f";
sha256 = "1l9s22fkjf7wc0zd3wjax4hlif7gqh6ij0ijb8sq20mfh2xl4hj8";
};
};
"ordered-collections" = pkgs.stdenv.mkDerivation {
name = "ordered-collections";
version = "v1.6.1";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-ordered-collections.git";
rev = "54af8b281bf01acfc14e147debec76974901e93c";
sha256 = "0r48p94d3cyzni2z7ikzcap472k23dx8zq37c1prmjb01v03mfvc";
};
};
"orders" = pkgs.stdenv.mkDerivation {
name = "orders";
version = "v4.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-orders.git";
rev = "80e22c22c72c846e09ef9dfcdb40b3eee39118d6";
sha256 = "13p1sm4dxkmxhld9x5qqg62iiajjb3qpzs66c1r24y5fs4zsfry4";
};
};
"parallel" = pkgs.stdenv.mkDerivation {
name = "parallel";
version = "v4.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-parallel.git";
rev = "4d6c8b05041a36c300dfca2ba8f1f3443ca26bc6";
sha256 = "1d5bnagabw2k8yxywkygwrpblb2ggqh2fhpqfrx2sj1y53x332hg";
};
};
"parsing" = pkgs.stdenv.mkDerivation {
name = "parsing";
version = "v5.0.3";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-parsing.git";
rev = "e801a0ef42f3211b1602a94a269eef7ce551423f";
sha256 = "0m5xvb5kis28laj3navyyakyq408vw115c2dvngf1vljzh1hk5kj";
};
};
"partial" = pkgs.stdenv.mkDerivation {
name = "partial";
version = "v2.0.1";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-partial.git";
rev = "76b63a324f7eafbb859256771b5bb7404082af96";
sha256 = "11qr80989g7xmvw1brnrclsbg2wdkbr5k3cqpngfip3nnirrypcn";
};
};
"pipes" = pkgs.stdenv.mkDerivation {
name = "pipes";
version = "v6.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/felixSchl/purescript-pipes.git";
rev = "a9533035f6fe8e59a65c6d11a3a7c767f3c9ae67";
sha256 = "0vl37f42dy4w4hswiay22w0n14k7sr670x54iwn7428larzrzs8y";
};
};
"precise" = pkgs.stdenv.mkDerivation {
name = "precise";
version = "v4.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-precise";
rev = "05679ad25771a9dd17f3ea892d4005680c61b654";
sha256 = "18677n91h4dlfn07h7i6bwcngr6pp55w6nf4x6slq7v0n3a6xs5k";
};
};
"prelude" = pkgs.stdenv.mkDerivation {
name = "prelude";
version = "v4.1.1";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-prelude.git";
rev = "a96663b34364fdd0885a200955e35b99f4e58c43";
sha256 = "1frvjrv0mr508r6683l1mp5rzm1y2dz76fz40zf4k2c64sy6y1xm";
};
};
"profunctor" = pkgs.stdenv.mkDerivation {
name = "profunctor";
version = "v4.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-profunctor.git";
rev = "1de584baf49624cc0d1686067d82b93523654c1b";
sha256 = "1v4kvmhmiwznd4lswp9339h64pgv5zvd3vm1q7gzj70767a3941i";
};
};
"profunctor-lenses" = pkgs.stdenv.mkDerivation {
name = "profunctor-lenses";
version = "v6.2.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-profunctor-lenses.git";
rev = "a058930ab7c73f5c4676a0cc91ea1a7433300c17";
sha256 = "0bb8ib00in8d65kvympdlfncb7bp1qqsjvvpw9zfwiwf67ix4v57";
};
};
"proxy" = pkgs.stdenv.mkDerivation {
name = "proxy";
version = "v3.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-proxy.git";
rev = "4a529b1f874fa2f32fc4c575cafaf46e0ab69fb6";
sha256 = "0rqf25b1n9p5sgx7gdsxwrfv9rb3sqxgqmqpp5kdm30lfk7snz24";
};
};
"psci-support" = pkgs.stdenv.mkDerivation {
name = "psci-support";
version = "v4.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-psci-support.git";
rev = "a66a0fa8661eb8b5fe75cc862f4e2df2835c058d";
sha256 = "0jd773zcklr6hjddqingzmk20a0afpm2r9pczfjbj0d93pbxb4xh";
};
};
"quickcheck" = pkgs.stdenv.mkDerivation {
name = "quickcheck";
version = "v6.1.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-quickcheck.git";
rev = "6289a80570acd5aec3ea89dc673cf10cdaf5794a";
sha256 = "0b6208067krf81kzq2hbxs68386hcicbscwxbj5nck07ivjjvqh0";
};
};
"random" = pkgs.stdenv.mkDerivation {
name = "random";
version = "v4.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-random.git";
rev = "75e6b21edbe0eec78c28ff3bd8265998f2ea0b45";
sha256 = "0k37v7z529adx6ypxj0xjyfrz45qia6p0vki2wpvi8lik7c698gf";
};
};
"react" = pkgs.stdenv.mkDerivation {
name = "react";
version = "v7.0.1";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-react.git";
rev = "a2e40f93f0dd47a6e185462431799e0e0c6e8667";
sha256 = "0kym675db8i4wzd0rh1f17k4mcfbf4pwnhpf7zhzkm9zaj7wc2cg";
};
};
"react-dom" = pkgs.stdenv.mkDerivation {
name = "react-dom";
version = "v6.1.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-react-dom.git";
rev = "441e1705ab8fc5fb382d9b3b3516f40ef7234e6c";
sha256 = "19kzsahx3kvgbi9bhnnz50fjmqvvgslsg6rk028bj4v28m8gra40";
};
};
"reactix" = pkgs.stdenv.mkDerivation {
name = "reactix";
version = "v0.4.3";
fetched = pkgs.fetchgit {
url = "https://github.com/irresponsible/purescript-reactix";
rev = "9305a56faeab499b86195ba33067666a625e8dad";
sha256 = "0sg80qs7siswqvwfcsggjqvn9viqhxpkr452alyyslx5c3p2xamw";
};
};
"read" = pkgs.stdenv.mkDerivation {
name = "read";
version = "v1.0.1";
fetched = pkgs.fetchgit {
url = "https://github.com/truqu/purescript-read";
rev = "b3969a2091fea50c57ed806820e3d725c8ef8992";
sha256 = "0q8c1xbwh781c1jngy04lbbaq44idy33klq7q1j5ax4vzgd54z0f";
};
};
"record" = pkgs.stdenv.mkDerivation {
name = "record";
version = "v2.0.1";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-record.git";
rev = "42a15ba34d860f4d8f899836956bf09659a0256b";
sha256 = "1l7ixb0gc2man36181g3hdf46sjp7xh0kv8bgrvalxfisjmd12v0";
};
};
"record-extra" = pkgs.stdenv.mkDerivation {
name = "record-extra";
version = "v3.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/justinwoo/purescript-record-extra.git";
rev = "41a837de4168b60790c53d9cb18bc7fb6961bb17";
sha256 = "1zhsgafd02h7161xldnf4z3sfjacp2if8py157igiszkjxaipvdd";
};
};
"refs" = pkgs.stdenv.mkDerivation {
name = "refs";
version = "v4.1.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-refs.git";
rev = "e8b175477661e433175e76548168290c40e0ce4b";
sha256 = "08161iy1xbafzblv033v84156azpcqkiw9v9d6gliphrq5fm17gm";
};
};
"routing" = pkgs.stdenv.mkDerivation {
name = "routing";
version = "v9.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/slamdata/purescript-routing.git";
rev = "62742c314b7a30118399f1b98fdec27212f8f40e";
sha256 = "1q05k1nrwpmlwy35fwa6kp1drk1ywnf5srmm1rzpliprvpli3is7";
};
};
"semirings" = pkgs.stdenv.mkDerivation {
name = "semirings";
version = "v5.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-semirings.git";
rev = "36aedc601d296607439eec1e71f8483adc373ffc";
sha256 = "0bhrhn2yvcgil7g63spb2xw966mdhlk9mpspnqfijdpb9n3b79ds";
};
};
"sequences" = pkgs.stdenv.mkDerivation {
name = "sequences";
version = "v2.1.0";
fetched = pkgs.fetchgit {
url = "https://github.com/hdgarrood/purescript-sequences.git";
rev = "448919594e979cfd2a45ebcde619c22a9fb984fc";
sha256 = "10fkkmmb7qh4p5gmgb6xpxh9g8hy06ddy8cyfrs3py8a5b8h46hw";
};
};
"smolder" = pkgs.stdenv.mkDerivation {
name = "smolder";
version = "v12.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/bodil/purescript-smolder.git";
rev = "1ac78c3ba802baf1e7cb235aebc14434c66fbe01";
sha256 = "1v8707hgm9g4k30afc30cxzfcz627bmxf7cn9wk3l3mh9ppl8kwd";
};
};
"spec" = pkgs.stdenv.mkDerivation {
name = "spec";
version = "v4.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript-spec/purescript-spec.git";
rev = "12bc11c4410dbd8060a6893fe5d07f350e4bb8ab";
sha256 = "1b1hw3231ha5fq61948dfz28a0lm2mcn2pksszf7yw3137ysp5bn";
};
};
"spec-discovery" = pkgs.stdenv.mkDerivation {
name = "spec-discovery";
version = "v4.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript-spec/purescript-spec-discovery";
rev = "b90ca588dc054c951201488d982765226a8393e9";
sha256 = "0kwc4nvy6rpbnhayang92h74fgyr28bh82pskwj7lm4sy513vhfw";
};
};
"spec-quickcheck" = pkgs.stdenv.mkDerivation {
name = "spec-quickcheck";
version = "v3.1.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript-spec/purescript-spec-quickcheck";
rev = "77a426996f7869f8424ed2720ab55c1f8d45bc84";
sha256 = "1l51v2j4z2cwdnf9hyx69jmlzlkk24l8gj38iphfspaiwyqwcmpg";
};
};
"st" = pkgs.stdenv.mkDerivation {
name = "st";
version = "v4.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-st.git";
rev = "c1b9a0d47a5be1d7ea713ef1c583040eb332250a";
sha256 = "0m2jkb9dmpbr8s1c20l7sm2q11y5rx8gqfiyspnyhq5apzkknjr0";
};
};
"string-parsers" = pkgs.stdenv.mkDerivation {
name = "string-parsers";
version = "v5.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/paf31/purescript-string-parsers.git";
rev = "ff023be7eeaf3dd129e652f9f1c225dfb196cf94";
sha256 = "1lykswyd3icv9lx4r096lxfd244i0pzj2f4fpm604czzlfw6bspv";
};
};
"strings" = pkgs.stdenv.mkDerivation {
name = "strings";
version = "v4.0.1";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-strings.git";
rev = "94c843b93142d0edf1c31ec075c40b6984c3dc7b";
sha256 = "147l3l3fzn7liparhm2y3p8j4ck1lblra5j493p2hy5yy5ndznc8";
};
};
"stringutils" = pkgs.stdenv.mkDerivation {
name = "stringutils";
version = "v0.0.9";
fetched = pkgs.fetchgit {
url = "https://github.com/menelaos/purescript-stringutils.git";
rev = "7983cde4aa1edac2b31611eb7c1fd17abcff667c";
sha256 = "00c679d5lk37gbfby2kasyq45rla6a0shg64zhyd2r4xrj0a74r4";
};
};
"tailrec" = pkgs.stdenv.mkDerivation {
name = "tailrec";
version = "v4.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-tailrec.git";
rev = "69f4625969e313203028968e4a9f743fa7f87883";
sha256 = "0z7k80nl8dgv8mc2w8xsl2n0637bd1l8ppxak8kaifgjjwa81hx3";
};
};
"thermite" = pkgs.stdenv.mkDerivation {
name = "thermite";
version = "hide-2020-03-04";
fetched = pkgs.fetchgit {
url = "https://github.com/poorscript/purescript-thermite.git";
rev = "ab62e1c1214a33a7584bf371998569d406c037a8";
sha256 = "1s0fj6f7kqafiw027yw65f5193kph51x6dxw0wv3g6j77yxmk92i";
};
};
"these" = pkgs.stdenv.mkDerivation {
name = "these";
version = "v4.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-these.git";
rev = "fc19af52b34f8f128f9981aa27aab4becd7a79d5";
sha256 = "0ywwpbcz1d0pdi3f9h9kla52vq1if8zwdz7jq7lqz5s8zj8kyg5r";
};
};
"transformers" = pkgs.stdenv.mkDerivation {
name = "transformers";
version = "v4.2.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-transformers.git";
rev = "0e473e5ef0e294615ca0d9aab0bcffee47b2870d";
sha256 = "03qmvl9s7lbvm73dy9ps6qp39pdcm91hb8yakgj7aq8hgpj7b6bg";
};
};
"tuples" = pkgs.stdenv.mkDerivation {
name = "tuples";
version = "v5.1.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-tuples.git";
rev = "0036bf9d99b721fd0f2e539d24e18e484b016927";
sha256 = "045nsy0r2g51gih0wjhcvhl6gfr8947mlrqwg644ygz72rjm8wq4";
};
};
"tuples-native" = pkgs.stdenv.mkDerivation {
name = "tuples-native";
version = "v2.0.1";
fetched = pkgs.fetchgit {
url = "https://github.com/athanclark/purescript-tuples-native";
rev = "ec3afab3379d3282f18e8d63da309220f17c8907";
sha256 = "1c8065krignnphiwnws9d5ingfx8k83wqnmd1zadyjlakfdg2b4h";
};
};
"type-equality" = pkgs.stdenv.mkDerivation {
name = "type-equality";
version = "v3.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-type-equality.git";
rev = "2cdae51c394401cd5fc04b03c341273b41532b7d";
sha256 = "1b7szyca5s96gaawvgwrw7fa8r7gqsdff7xhz3vvngnylv2scl3w";
};
};
"typelevel" = pkgs.stdenv.mkDerivation {
name = "typelevel";
version = "v5.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/bodil/purescript-typelevel.git";
rev = "5ce2e704fd86f66ccb40a81366146811a1e1fb16";
sha256 = "1s0fdffmn386hahv670fc5vvj0x0cqk64i4jj95rfavffch4x7va";
};
};
"typelevel-prelude" = pkgs.stdenv.mkDerivation {
name = "typelevel-prelude";
version = "v5.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-typelevel-prelude.git";
rev = "82b343fabfe3bf4ebf8106ce61bfe24fb3ed500c";
sha256 = "01ki39xj87kwf8j8divlzwrvfyjcgxpmzhhmxzjylqx6jarcwyg6";
};
};
"uint" = pkgs.stdenv.mkDerivation {
name = "uint";
version = "v5.1.1";
fetched = pkgs.fetchgit {
url = "https://github.com/zaquest/purescript-uint";
rev = "9d89e0e4fe231a1ac8466b70a7c2315ce11a6dd7";
sha256 = "13103kqj2abiy8p7v81w1dj8jm0mll177mfjb7ar6km0bsxjigc6";
};
};
"unfoldable" = pkgs.stdenv.mkDerivation {
name = "unfoldable";
version = "v4.0.2";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-unfoldable.git";
rev = "be3262a9dc48e794676b1b2883987331d4be6fd7";
sha256 = "0lzhx030c5933maxcjwk6kzlvbxky1kiwrymqf1dp5wbrar3jyv4";
};
};
"unicode" = pkgs.stdenv.mkDerivation {
name = "unicode";
version = "v4.0.1";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript-contrib/purescript-unicode.git";
rev = "bb70f5a17aa9bcad05104c5a3f191fd75bb3d2ce";
sha256 = "1a53jv7pzyjk5v6kmwwy50d3l8d26k0id59sn8g3lzkih24nalhp";
};
};
"unsafe-coerce" = pkgs.stdenv.mkDerivation {
name = "unsafe-coerce";
version = "v4.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-unsafe-coerce.git";
rev = "fa6a5ca9b4581c00ee0b8539306a49badb7bee60";
sha256 = "0k9255mk2mz6xjb11pwkgfcblmmyvr86ig5kr92jwy95xim09zip";
};
};
"uri" = pkgs.stdenv.mkDerivation {
name = "uri";
version = "v7.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/slamdata/purescript-uri";
rev = "e48b2e9153aeb06e6b234be98c79159dfc0f6d10";
sha256 = "1ry5h5656k2hn3y5s35y7pz0rngbkvj9jc783i4h9ai3hndi00py";
};
};
"validation" = pkgs.stdenv.mkDerivation {
name = "validation";
version = "v4.2.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript/purescript-validation.git";
rev = "bef3f9da737516e69f00d35310334004c29355cb";
sha256 = "03irk6n7jgsimhp9ckrg2ns7qbc8d383ls3sslxgir5mr8xdc44g";
};
};
"versions" = pkgs.stdenv.mkDerivation {
name = "versions";
version = "v5.0.1";
fetched = pkgs.fetchgit {
url = "https://github.com/hdgarrood/purescript-versions.git";
rev = "5da24cc63a1fa9a3d09156afa49ad49b3c0fff84";
sha256 = "07h2s3411w9d0iany7arw01qvfj57wgj8pgfqvrm0vvvhhc0v9f6";
};
};
"web-dom" = pkgs.stdenv.mkDerivation {
name = "web-dom";
version = "v3.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript-web/purescript-web-dom.git";
rev = "0c47ae3e37407c10789712137381f7899d1ac3a0";
sha256 = "14mssfhg81diy82wbv3ja8zk9a92267c6svq4bgfag91hydw4p42";
};
};
"web-events" = pkgs.stdenv.mkDerivation {
name = "web-events";
version = "v2.0.1";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript-web/purescript-web-events.git";
rev = "7f19f24d7b61066bef0813734964f2dc6b085e3d";
sha256 = "1vd1gfh6zv50bq4v1ppl2wvc5mskcw9n1bfj29qjg0dx0ffxzv2f";
};
};
"web-file" = pkgs.stdenv.mkDerivation {
name = "web-file";
version = "v2.1.1";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript-web/purescript-web-file.git";
rev = "5245d62ba35357c6fb74fa919797d2b7c08110cd";
sha256 = "08k0xv9zpg040v32k3wk66bhzx16c2nn9v35f01gq96anhm713s1";
};
};
"web-html" = pkgs.stdenv.mkDerivation {
name = "web-html";
version = "v2.2.1";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript-web/purescript-web-html.git";
rev = "6f0d367f737202fdf9638f1f6836716c26456014";
sha256 = "026y4kkrc2z4zmxlc4z21znq8knaqqjazf1ny811gm1507b1ykc6";
};
};
"web-storage" = pkgs.stdenv.mkDerivation {
name = "web-storage";
version = "v3.0.0";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript-web/purescript-web-storage.git";
rev = "c2dedea1ee10ca7e94af5547c90274fb63ab3bc6";
sha256 = "1ycb2s29aw9w6lqik6hfmp9nf9i2yhn0q26hc4p3450jam5mj8bx";
};
};
"web-xhr" = pkgs.stdenv.mkDerivation {
name = "web-xhr";
version = "v3.0.1";
fetched = pkgs.fetchgit {
url = "https://github.com/purescript-web/purescript-web-xhr.git";
rev = "eb1db72a670b3b98877f33940dbe37097b722736";
sha256 = "1217lmvla3rqd9kzvvjxpngj7nxjn2ianm9xhlc0iydzsd0agihi";
};
};
}
{ pkgs ? import ./pinned.nix {} }: { pkgs ? import ./nix/pinned.nix {} }:
let let
easy-ps = import ( easy-ps = import ./nix/easy-ps.nix { inherit pkgs; };
pkgs.fetchFromGitHub {
owner = "justinwoo";
repo = "easy-purescript-nix";
rev = "14e7d85431e9f9838d7107d18cb79c7fa534f54e";
sha256 = "0lmkppidmhnayv0919990ifdd61f9d23dzjzr8amz7hjgc74yxs0";
}
) {
inherit pkgs;
};
soba = import (
pkgs.fetchFromGitHub {
owner = "justinwoo";
repo = "soba";
rev = "2add8804bce7e7c1ab5eb1c3d8f6783e938a04d3";
sha256 = "1qagyklcllr2sxdb315prw33af6g37762zgk2ahh3ifxpns6ifxx";
}
) {
inherit pkgs;
};
purs-packages = import ./purs-packages.nix { inherit pkgs; }; purs-packages = import ./purs-packages.nix { inherit pkgs; };
cpPackage = pp: purs-project = import ./nix/purs-project.nix { inherit pkgs; };
let
target = ".psc-package/local/${pp.name}/${pp.version}";
in
''
mkdir -p ${target}
cp --no-preserve=mode,ownership,timestamp -r ${pp.fetched.outPath}/* ${target}
'';
install-purs-packages = pkgs.writeShellScriptBin "install-purs-packages" ''
#!/usr/bin/env bash
${builtins.toString (builtins.map cpPackage (builtins.attrValues purs-packages))}
echo done installing deps.
'';
build-purs = pkgs.writeShellScriptBin "build-purs" '' build-purs = pkgs.writeShellScriptBin "build-purs" ''
#!/usr/bin/env bash #!/usr/bin/env bash
purs compile "src/**/*.purs" ".psc-package/*/*/*/src/**/*.purs" purs compile ${toString purs-project.sourceGlobs} "src/**/*.purs" "test/**/*.purs"
'';
storePath = x: ''"${x.fetched.outPath}/src/**/*.purs"'';
build-purs-from-store = pkgs.writeShellScriptBin "build-purs-from-store" ''
#!/usr/bin/env bash
purs compile "src/**/*.purs" \
${builtins.toString (builtins.map storePath (builtins.attrValues purs-packages))}
''; '';
build = pkgs.writeShellScriptBin "build" '' build = pkgs.writeShellScriptBin "build" ''
...@@ -57,7 +16,7 @@ let ...@@ -57,7 +16,7 @@ let
set -e set -e
echo "Compiling" echo "Compiling"
build-purs-from-store build-purs
echo "Bundling" echo "Bundling"
yarn pulp browserify --skip-compile -t dist/bundle.js --src-path output yarn pulp browserify --skip-compile -t dist/bundle.js --src-path output
''; '';
...@@ -72,28 +31,28 @@ pkgs.mkShell { ...@@ -72,28 +31,28 @@ pkgs.mkShell {
buildInputs = [ buildInputs = [
easy-ps.purs easy-ps.purs
easy-ps.psc-package easy-ps.psc-package
soba
install-purs-packages
build-purs build-purs
build-purs-from-store
build build
repl repl
pkgs.yarn pkgs.yarn
]; ];
shellHook = ''
export PURS_IDE_SOURCES='${toString purs-project.unquotedSourceGlobs}'
'';
} }
## how to build the project with nix dependencies: ## how to build the project with nix dependencies:
# #
# 1. start a nix shell (e.g. `nix-shell -j 20`, this uses 20 jobs to fetch deps) # 1. start a nix shell (e.g. `nix-shell -j 20`, this uses 20 jobs to fetch deps)
# 2. run `yarn` to install npm deps # 2. run `yarn` to install npm deps
# 3. run `install-purs-packages` if you want dependencies locally, available for psc-package and for inspection # 3a. run `build-purs` to build using nix store dependencies, and make sure to update your purescript ide tooling as necesssary
# 4. run `build-purs` to build from local sources. otherwise use `build-purs-from-store`. # 3b. or simply use `psc-package` as you might want to anyway
# #
# note that the purescript compiler uses filepaths and timestamps, so using the above two commands # note that the purescript compiler uses filepaths and timestamps, so using the above two commands
# interchangeably will lead to constant rebuilding of the entire project. # interchangeably will lead to constant rebuilding of the entire project.
# #
## how to update purs-packages.nix ## how to update purs-packages.nix
# #
# 1. run `soba insdhall` to generate packages.json # 1. run `nix/generate-packages-json.nix` to generate packages.json
# 2. run `soba nix` to generate a nix derivation from packages.json # 2. run `nix/generate-purs-packages.nix` to generate purs-packages.nix
...@@ -8,6 +8,11 @@ import Data.Tuple (Tuple(..), fst, snd) ...@@ -8,6 +8,11 @@ import Data.Tuple (Tuple(..), fst, snd)
import Data.Tuple.Nested ((/\)) import Data.Tuple.Nested ((/\))
import Effect.Aff (Aff) import Effect.Aff (Aff)
import Effect.Class (liftEffect) import Effect.Class (liftEffect)
import Reactix as R
import Reactix.DOM.HTML as H
import Record as Record
import Record.Extra as RecordE
import Gargantext.AsyncTasks as GAT import Gargantext.AsyncTasks as GAT
import Gargantext.Components.Forest.Tree.Node (nodeMainSpan) import Gargantext.Components.Forest.Tree.Node (nodeMainSpan)
import Gargantext.Components.Forest.Tree.Node.Tools.SubTree.Types (SubTreeOut(..)) import Gargantext.Components.Forest.Tree.Node.Tools.SubTree.Types (SubTreeOut(..))
...@@ -31,10 +36,6 @@ import Gargantext.Sessions (OpenNodes, Session, mkNodeId, get) ...@@ -31,10 +36,6 @@ import Gargantext.Sessions (OpenNodes, Session, mkNodeId, get)
import Gargantext.Types (ID, Reload) import Gargantext.Types (ID, Reload)
import Gargantext.Types as GT import Gargantext.Types as GT
import Gargantext.Routes as GR import Gargantext.Routes as GR
import Reactix as R
import Reactix.DOM.HTML as H
import Record as Record
import Record.Extra as RecordE
------------------------------------------------------------------------ ------------------------------------------------------------------------
type CommonProps = type CommonProps =
......
...@@ -8,16 +8,20 @@ import Reactix as R ...@@ -8,16 +8,20 @@ import Reactix as R
import Gargantext.Prelude import Gargantext.Prelude
import Gargantext.Components.Nodes.Corpus.Chart.Types import Gargantext.Components.Nodes.Corpus.Chart.Types (Reload, Path, Props, MetricsProps, ReloadPath)
import Gargantext.Hooks.Loader (HashedResponse, useLoader, useLoaderWithCache) import Gargantext.Hooks.Loader (MD5, HashedResponse, useLoader, useLoaderWithCache, useLoaderWithCacheAPI)
import Gargantext.Sessions (Session) import Gargantext.Sessions (Session)
import Gargantext.Utils.CacheAPI as GUC
type MetricsLoadViewProps a = ( type MetricsLoadViewProps a = (
getMetrics :: Session -> Tuple Reload (Record Path) -> Aff a getMetrics :: Session -> ReloadPath -> Aff a
, loaded :: Session -> Record Path -> R.State Reload -> a -> R.Element , loaded :: Record MetricsProps -> a -> R.Element
| MetricsProps | MetricsProps
) )
cacheName :: String
cacheName = "metrics"
metricsLoadView :: forall a. Record (MetricsLoadViewProps a) -> R.Element metricsLoadView :: forall a. Record (MetricsLoadViewProps a) -> R.Element
metricsLoadView p = R.createElement metricsLoadViewCpt p [] metricsLoadView p = R.createElement metricsLoadViewCpt p []
...@@ -26,25 +30,32 @@ metricsLoadViewCpt = R.hooksComponent "G.C.N.C.C.metricsLoadView" cpt ...@@ -26,25 +30,32 @@ metricsLoadViewCpt = R.hooksComponent "G.C.N.C.C.metricsLoadView" cpt
where where
cpt { getMetrics, loaded, path, reload, session } _ = do cpt { getMetrics, loaded, path, reload, session } _ = do
useLoader (fst reload /\ path) (getMetrics session) $ \l -> useLoader (fst reload /\ path) (getMetrics session) $ \l ->
loaded session path reload l loaded { path, reload, session } l
type MetricsWithCacheLoadViewProps a = ( type MetricsWithCacheLoadViewProps res ret = (
keyFunc :: Tuple Reload (Record Path) -> String getMetricsMD5 :: Session -> ReloadPath -> Aff MD5
, getMetrics :: Session -> Tuple Reload (Record Path) -> Aff (HashedResponse a) , handleResponse :: HashedResponse res -> ret
, getMetricsMD5 :: Session -> Tuple Reload (Record Path) -> Aff String , loaded :: Record MetricsProps -> ret -> R.Element
, loaded :: Session -> Record Path -> R.State Reload -> a -> R.Element , mkRequest :: ReloadPath -> GUC.Request
| MetricsProps | MetricsProps
) )
metricsWithCacheLoadView :: forall a. DecodeJson a => EncodeJson a => metricsWithCacheLoadView :: forall res ret. DecodeJson res =>
Record (MetricsWithCacheLoadViewProps a) -> R.Element Record (MetricsWithCacheLoadViewProps res ret) -> R.Element
metricsWithCacheLoadView p = R.createElement metricsWithCacheLoadViewCpt p [] metricsWithCacheLoadView p = R.createElement metricsWithCacheLoadViewCpt p []
metricsWithCacheLoadViewCpt :: forall a. DecodeJson a => EncodeJson a => R.Component (MetricsWithCacheLoadViewProps a) metricsWithCacheLoadViewCpt :: forall res ret. DecodeJson res =>
R.Component (MetricsWithCacheLoadViewProps res ret)
metricsWithCacheLoadViewCpt = R.hooksComponent "G.C.N.C.C.metricsWithCacheLoadView" cpt metricsWithCacheLoadViewCpt = R.hooksComponent "G.C.N.C.C.metricsWithCacheLoadView" cpt
where where
cpt { getMetrics, getMetricsMD5, keyFunc, loaded, path, reload, session } _ = do cpt { getMetricsMD5, handleResponse, loaded, mkRequest, path, reload, session } _ = do
useLoaderWithCache (fst reload /\ path) (metricsKeyFunc keyFunc) (getMetricsMD5 session) (getMetrics session) $ \l -> -- useLoaderWithCache (fst reload /\ path) (metricsKeyFunc keyFunc) (getMetricsMD5 session) (getMetrics session) $ \l ->
loaded session path reload l -- loaded session path reload l
metricsKeyFunc keyFunc st@(_ /\ { corpusId, listId, tabType }) = -- metricsKeyFunc keyFunc st@(_ /\ { corpusId, listId, tabType }) =
"metrics-" <> (show tabType) <> "-" <> (show corpusId) <> "-" <> (show listId) <> "--" <> (keyFunc st) -- "metrics-" <> (show tabType) <> "-" <> (show corpusId) <> "-" <> (show listId) <> "--" <> (keyFunc st)
useLoaderWithCacheAPI { cacheEndpoint: (getMetricsMD5 session)
, handleResponse
, mkRequest
, path: (fst reload /\ path)
, renderer: loaded { path, reload, session } }
...@@ -23,6 +23,7 @@ import Gargantext.Hooks.Loader (HashedResponse(..)) ...@@ -23,6 +23,7 @@ import Gargantext.Hooks.Loader (HashedResponse(..))
import Gargantext.Routes (SessionRoute(..)) import Gargantext.Routes (SessionRoute(..))
import Gargantext.Sessions (Session, get) import Gargantext.Sessions (Session, get)
import Gargantext.Types (ChartType(..), TabType(..)) import Gargantext.Types (ChartType(..), TabType(..))
import Gargantext.Utils.CacheAPI as GUC
newtype ChartMetrics = ChartMetrics { newtype ChartMetrics = ChartMetrics {
"data" :: HistoMetrics "data" :: HistoMetrics
...@@ -61,30 +62,46 @@ chartOptions (HistoMetrics { dates: dates', count: count'}) = Options ...@@ -61,30 +62,46 @@ chartOptions (HistoMetrics { dates: dates', count: count'}) = Options
, series : [seriesBarD1 {name: "Number of publication / year"} $ , series : [seriesBarD1 {name: "Number of publication / year"} $
map (\n -> dataSerie {value: n, itemStyle : itemStyle {color:grey}}) count'] } map (\n -> dataSerie {value: n, itemStyle : itemStyle {color:grey}}) count'] }
getMetrics :: Session -> Tuple Reload (Record Path) -> Aff (HashedResponse HistoMetrics) -- getMetrics :: Session -> Tuple Reload (Record Path) -> Aff (HashedResponse HistoMetrics)
getMetrics session (_ /\ { corpusId, limit, listId, tabType }) = do -- getMetrics session (_ /\ { corpusId, limit, listId, tabType }) = do
HashedResponse { md5, value: ChartMetrics ms } <- get session chart -- HashedResponse { md5, value: ChartMetrics ms } <- get session chart
pure $ HashedResponse { md5, value: ms."data" } -- pure $ HashedResponse { md5, value: ms."data" }
where -- where
chart = Chart {chartType: Histo, listId, tabType, limit} (Just corpusId) -- chart = Chart {chartType: Histo, listId, tabType, limit} (Just corpusId)
getMetricsMD5 :: Session -> Tuple Reload (Record Path) -> Aff String getMetricsMD5 :: Session -> Tuple Reload (Record Path) -> Aff String
getMetricsMD5 session (_ /\ { corpusId, limit, listId, tabType }) = do getMetricsMD5 session (_ /\ { corpusId, limit, listId, tabType }) = do
get session $ ChartMD5 { chartType: Histo, listId, tabType } (Just corpusId) get session $ ChartMD5 { chartType: Histo, listId, tabType } (Just corpusId)
chartUrl :: Record Path -> SessionRoute
chartUrl { corpusId, limit, listId, tabType } = Chart {chartType: Histo, limit, listId, tabType} (Just corpusId)
handleResponse :: HashedResponse ChartMetrics -> HistoMetrics
handleResponse (HashedResponse { value: ChartMetrics ms }) = ms."data"
mkRequest :: Session -> ReloadPath -> GUC.Request
mkRequest session (_ /\ path@{ corpusId, limit, listId, tabType }) = GUC.makeGetRequest session $ chartUrl path
histo :: Record Props -> R.Element histo :: Record Props -> R.Element
histo props = R.createElement histoCpt props [] histo props = R.createElement histoCpt props []
histoCpt :: R.Component Props histoCpt :: R.Component Props
histoCpt = R.hooksComponent "G.C.N.C.C.H.histo" cpt histoCpt = R.hooksComponent "G.C.N.C.C.H.histo" cpt
where where
cpt {path, session} _ = do cpt { path, session } _ = do
reload <- R.useState' 0 reload <- R.useState' 0
--pure $ metricsLoadView {getMetrics, loaded, path, reload, session} pure $ metricsWithCacheLoadView {
pure $ metricsWithCacheLoadView { getMetrics, getMetricsMD5, keyFunc: const "histo", loaded, path, reload, session } getMetricsMD5
, handleResponse
, loaded
, mkRequest: mkRequest session
, path
, reload
, session
}
loaded :: Session -> Record Path -> R.State Reload -> HistoMetrics -> R.Element loaded :: Record MetricsProps -> HistoMetrics -> R.Element
loaded session path reload loaded = loaded { path, reload, session } loaded =
H.div {} [ H.div {} [
U.reloadButton reload U.reloadButton reload
, U.chartUpdateButton { chartType: Histo, path, reload, session } , U.chartUpdateButton { chartType: Histo, path, reload, session }
......
...@@ -26,6 +26,7 @@ import Gargantext.Hooks.Loader (HashedResponse(..)) ...@@ -26,6 +26,7 @@ import Gargantext.Hooks.Loader (HashedResponse(..))
import Gargantext.Routes (SessionRoute(..)) import Gargantext.Routes (SessionRoute(..))
import Gargantext.Sessions (Session, get) import Gargantext.Sessions (Session, get)
import Gargantext.Types (ChartType(..), TabType, TermList(..)) import Gargantext.Types (ChartType(..), TabType, TermList(..))
import Gargantext.Utils.CacheAPI as GUC
newtype Metric = Metric newtype Metric = Metric
{ label :: String { label :: String
...@@ -97,17 +98,26 @@ scatterOptions metrics' = Options ...@@ -97,17 +98,26 @@ scatterOptions metrics' = Options
} }
--} --}
getMetrics :: Session -> Tuple Reload (Record Path) -> Aff (HashedResponse Loaded) -- getMetrics :: Session -> Tuple Reload (Record Path) -> Aff (HashedResponse Loaded)
getMetrics session (_ /\ { corpusId, limit, listId, tabType }) = do -- getMetrics session (_ /\ { corpusId, limit, listId, tabType }) = do
HashedResponse { md5, value: Metrics ms } <- get session metrics' -- HashedResponse { md5, value: Metrics ms } <- get session metrics'
pure $ HashedResponse { md5, value: ms."data" } -- pure $ HashedResponse { md5, value: ms."data" }
where -- where
metrics' = CorpusMetrics {limit, listId, tabType} (Just corpusId) -- metrics' = CorpusMetrics {limit, listId, tabType} (Just corpusId)
getMetricsMD5 :: Session -> Tuple Reload (Record Path) -> Aff String getMetricsMD5 :: Session -> Tuple Reload (Record Path) -> Aff String
getMetricsMD5 session (_ /\ { corpusId, listId, tabType }) = getMetricsMD5 session (_ /\ { corpusId, listId, tabType }) =
get session $ CorpusMetricsMD5 { listId, tabType } (Just corpusId) get session $ CorpusMetricsMD5 { listId, tabType } (Just corpusId)
chartUrl :: Record Path -> SessionRoute
chartUrl { corpusId, limit, listId, tabType } = CorpusMetrics { limit, listId, tabType } (Just corpusId)
handleResponse :: HashedResponse Metrics -> Loaded
handleResponse (HashedResponse { value: Metrics ms }) = ms."data"
mkRequest :: Session -> ReloadPath -> GUC.Request
mkRequest session (_ /\ path@{ corpusId, limit, listId, tabType }) = GUC.makeGetRequest session $ chartUrl path
metrics :: Record Props -> R.Element metrics :: Record Props -> R.Element
metrics props = R.createElement metricsCpt props [] metrics props = R.createElement metricsCpt props []
...@@ -116,13 +126,19 @@ metricsCpt = R.hooksComponent "G.C.N.C.C.M.metrics" cpt ...@@ -116,13 +126,19 @@ metricsCpt = R.hooksComponent "G.C.N.C.C.M.metrics" cpt
where where
cpt {path, session} _ = do cpt {path, session} _ = do
reload <- R.useState' 0 reload <- R.useState' 0
--pure $ metricsLoadView {getMetrics, loaded, path, reload, session} pure $ metricsWithCacheLoadView {
getMetricsMD5
pure $ metricsWithCacheLoadView { getMetrics, getMetricsMD5, keyFunc: const "metrics", loaded, path, reload, session } , handleResponse
, loaded
, mkRequest: mkRequest session
loaded :: Session -> Record Path -> R.State Reload -> Loaded -> R.Element , path
loaded session path reload loaded = , reload
, session
}
loaded :: Record MetricsProps -> Loaded -> R.Element
loaded { path, reload, session } loaded =
H.div {} [ H.div {} [
U.reloadButton reload U.reloadButton reload
, U.chartUpdateButton { chartType: Scatter, path, reload, session } , U.chartUpdateButton { chartType: Scatter, path, reload, session }
......
...@@ -26,6 +26,7 @@ import Gargantext.Hooks.Loader (HashedResponse(..)) ...@@ -26,6 +26,7 @@ import Gargantext.Hooks.Loader (HashedResponse(..))
import Gargantext.Routes (SessionRoute(..)) import Gargantext.Routes (SessionRoute(..))
import Gargantext.Sessions (Session, get) import Gargantext.Sessions (Session, get)
import Gargantext.Types (ChartType(..), TabType) import Gargantext.Types (ChartType(..), TabType)
import Gargantext.Utils.CacheAPI as GUC
newtype ChartMetrics = ChartMetrics { newtype ChartMetrics = ChartMetrics {
"data" :: HistoMetrics "data" :: HistoMetrics
...@@ -81,29 +82,45 @@ chartOptionsPie (HistoMetrics { dates: dates', count: count'}) = Options ...@@ -81,29 +82,45 @@ chartOptionsPie (HistoMetrics { dates: dates', count: count'}) = Options
} }
getMetrics :: Session -> Tuple Reload (Record Path) -> Aff (HashedResponse HistoMetrics) -- getMetrics :: Session -> Tuple Reload (Record Path) -> Aff (HashedResponse HistoMetrics)
getMetrics session (_ /\ { corpusId, limit, listId, tabType }) = do -- getMetrics session (_ /\ { corpusId, limit, listId, tabType }) = do
HashedResponse { md5, value: ChartMetrics ms } <- get session chart -- HashedResponse { md5, value: ChartMetrics ms } <- GUC.get session chart --get session chart
pure $ HashedResponse { md5, value: ms."data" } -- pure $ HashedResponse { md5, value: ms."data" }
where chart = Chart {chartType: ChartPie, limit, listId, tabType} (Just corpusId) -- where chart = Chart {chartType: ChartPie, limit, listId, tabType} (Just corpusId)
getMetricsMD5 :: Session -> Tuple Reload (Record Path) -> Aff String getMetricsMD5 :: Session -> Tuple Reload (Record Path) -> Aff String
getMetricsMD5 session (_ /\ { corpusId, limit, listId, tabType }) = do getMetricsMD5 session (_ /\ { corpusId, limit, listId, tabType }) = do
get session $ ChartMD5 { chartType: ChartPie, listId, tabType } (Just corpusId) get session $ ChartMD5 { chartType: ChartPie, listId, tabType } (Just corpusId)
chartUrl :: Record Path -> SessionRoute
chartUrl { corpusId, limit, listId, tabType } = Chart {chartType: ChartPie, limit, listId, tabType} (Just corpusId)
handleResponse :: HashedResponse ChartMetrics -> HistoMetrics
handleResponse (HashedResponse { value: ChartMetrics ms }) = ms."data"
mkRequest :: Session -> ReloadPath -> GUC.Request
mkRequest session (_ /\ path@{ corpusId, limit, listId, tabType }) = GUC.makeGetRequest session $ chartUrl path
pie :: Record Props -> R.Element pie :: Record Props -> R.Element
pie props = R.createElement pieCpt props [] pie props = R.createElement pieCpt props []
pieCpt :: R.Component Props pieCpt :: R.Component Props
pieCpt = R.hooksComponent "G.C.N.C.C.P.pie" cpt pieCpt = R.hooksComponent "G.C.N.C.C.P.pie" cpt
where where
cpt {path,session} _ = do cpt { path, session } _ = do
reload <- R.useState' 0 reload <- R.useState' 0
--pure $ metricsLoadView {getMetrics, loaded: loadedPie, path, reload, session} pure $ metricsWithCacheLoadView {
pure $ metricsWithCacheLoadView { getMetrics, getMetricsMD5, keyFunc: const "pie", loaded: loadedPie, path, reload, session } getMetricsMD5
, handleResponse
loadedPie :: Session -> Record Path -> R.State Reload -> HistoMetrics -> R.Element , loaded: loadedPie
loadedPie session path reload loaded = , mkRequest: mkRequest session
, path
, reload
, session
}
loadedPie :: Record MetricsProps -> HistoMetrics -> R.Element
loadedPie { path, reload, session } loaded =
H.div {} [ H.div {} [
U.reloadButton reload U.reloadButton reload
, U.chartUpdateButton { chartType: ChartPie, path, reload, session } , U.chartUpdateButton { chartType: ChartPie, path, reload, session }
...@@ -120,10 +137,18 @@ barCpt = R.hooksComponent "LoadedMetricsBar" cpt ...@@ -120,10 +137,18 @@ barCpt = R.hooksComponent "LoadedMetricsBar" cpt
cpt {path, session} _ = do cpt {path, session} _ = do
reload <- R.useState' 0 reload <- R.useState' 0
--pure $ metricsLoadView {getMetrics, loaded: loadedBar, path, reload, session} --pure $ metricsLoadView {getMetrics, loaded: loadedBar, path, reload, session}
pure $ metricsWithCacheLoadView { getMetrics, getMetricsMD5, keyFunc: const "bar", loaded: loadedBar, path, reload, session } pure $ metricsWithCacheLoadView {
getMetricsMD5
loadedBar :: Session -> Record Path -> R.State Reload -> Loaded -> R.Element , handleResponse
loadedBar session path reload loaded = , loaded: loadedPie
, mkRequest: mkRequest session
, path
, reload
, session
}
loadedBar :: Record MetricsProps -> Loaded -> R.Element
loadedBar { path, reload, session } loaded =
H.div {} [ H.div {} [
U.reloadButton reload U.reloadButton reload
, U.chartUpdateButton { chartType: ChartBar, path, reload, session } , U.chartUpdateButton { chartType: ChartBar, path, reload, session }
......
...@@ -21,6 +21,7 @@ import Gargantext.Hooks.Loader (HashedResponse(..)) ...@@ -21,6 +21,7 @@ import Gargantext.Hooks.Loader (HashedResponse(..))
import Gargantext.Routes (SessionRoute(..)) import Gargantext.Routes (SessionRoute(..))
import Gargantext.Sessions (Session, get) import Gargantext.Sessions (Session, get)
import Gargantext.Types (ChartType(..), TabType) import Gargantext.Types (ChartType(..), TabType)
import Gargantext.Utils.CacheAPI as GUC
newtype Metrics = Metrics { newtype Metrics = Metrics {
"data" :: Array TreeNode "data" :: Array TreeNode
...@@ -52,17 +53,26 @@ scatterOptions nodes = Options ...@@ -52,17 +53,26 @@ scatterOptions nodes = Options
} }
getMetrics :: Session -> Tuple Reload (Record Path) -> Aff (HashedResponse Loaded) -- getMetrics :: Session -> Tuple Reload (Record Path) -> Aff (HashedResponse Loaded)
getMetrics session (_ /\ { corpusId, limit, listId, tabType }) = do -- getMetrics session (_ /\ { corpusId, limit, listId, tabType }) = do
HashedResponse { md5, value: Metrics ms } <- get session chart -- HashedResponse { md5, value: Metrics ms } <- GUC.get session chart
pure $ HashedResponse { md5, value: ms."data" } -- pure $ HashedResponse { md5, value: ms."data" }
where -- where
chart = Chart {chartType : ChartTree, limit, listId, tabType} (Just corpusId) -- chart = Chart {chartType : ChartTree, limit, listId, tabType} (Just corpusId)
getMetricsMD5 :: Session -> Tuple Reload (Record Path) -> Aff String getMetricsMD5 :: Session -> Tuple Reload (Record Path) -> Aff String
getMetricsMD5 session (_ /\ { corpusId, limit, listId, tabType }) = do getMetricsMD5 session (_ /\ { corpusId, limit, listId, tabType }) = do
get session $ ChartMD5 { chartType: ChartTree, listId, tabType } (Just corpusId) get session $ ChartMD5 { chartType: ChartTree, listId, tabType } (Just corpusId)
chartUrl :: Record Path -> SessionRoute
chartUrl { corpusId, limit, listId, tabType } = Chart {chartType: ChartTree, limit, listId, tabType} (Just corpusId)
handleResponse :: HashedResponse Metrics -> Loaded
handleResponse (HashedResponse { value: Metrics ms }) = ms."data"
mkRequest :: Session -> ReloadPath -> GUC.Request
mkRequest session (_ /\ path@{ corpusId, limit, listId, tabType }) = GUC.makeGetRequest session $ chartUrl path
tree :: Record Props -> R.Element tree :: Record Props -> R.Element
tree props = R.createElement treeCpt props [] tree props = R.createElement treeCpt props []
...@@ -71,11 +81,18 @@ treeCpt = R.hooksComponent "G.C.N.C.C.T.tree" cpt ...@@ -71,11 +81,18 @@ treeCpt = R.hooksComponent "G.C.N.C.C.T.tree" cpt
where where
cpt {path, session} _ = do cpt {path, session} _ = do
reload <- R.useState' 0 reload <- R.useState' 0
--pure $ metricsLoadView {getMetrics, loaded, path, reload, session} pure $ metricsWithCacheLoadView {
pure $ metricsWithCacheLoadView { getMetrics, getMetricsMD5, keyFunc: const "tree", loaded, path, reload, session } getMetricsMD5
, handleResponse
, loaded
, mkRequest: mkRequest session
, path
, reload
, session
}
loaded :: Session -> Record Path -> R.State Reload -> Loaded -> R.Element loaded :: Record MetricsProps -> Loaded -> R.Element
loaded session path reload loaded = loaded { path, reload, session } loaded =
H.div {} [ H.div {} [
U.reloadButton reload U.reloadButton reload
, U.chartUpdateButton { chartType: ChartTree, path, reload, session } , U.chartUpdateButton { chartType: ChartTree, path, reload, session }
......
module Gargantext.Components.Nodes.Corpus.Chart.Types where module Gargantext.Components.Nodes.Corpus.Chart.Types where
import Data.Maybe (Maybe) import Data.Maybe (Maybe)
import Data.Tuple (Tuple)
import Reactix as R import Reactix as R
import Gargantext.Sessions (Session) import Gargantext.Sessions (Session)
...@@ -24,3 +25,5 @@ type MetricsProps = ( ...@@ -24,3 +25,5 @@ type MetricsProps = (
reload :: R.State Int reload :: R.State Int
| Props | Props
) )
type ReloadPath = Tuple Reload (Record Path)
...@@ -4,7 +4,7 @@ import Affjax (defaultRequest, printResponseFormatError, request) ...@@ -4,7 +4,7 @@ import Affjax (defaultRequest, printResponseFormatError, request)
import Affjax.RequestBody (RequestBody(..), formData, formURLEncoded) import Affjax.RequestBody (RequestBody(..), formData, formURLEncoded)
import Affjax.RequestHeader as ARH import Affjax.RequestHeader as ARH
import Affjax.ResponseFormat as ResponseFormat import Affjax.ResponseFormat as ResponseFormat
import DOM.Simple.Console (log) import DOM.Simple.Console (log, log2)
import Data.Argonaut (class DecodeJson, decodeJson, class EncodeJson, encodeJson) import Data.Argonaut (class DecodeJson, decodeJson, class EncodeJson, encodeJson)
import Data.Either (Either(..)) import Data.Either (Either(..))
import Data.Foldable (foldMap) import Data.Foldable (foldMap)
...@@ -12,13 +12,17 @@ import Data.FormURLEncoded as FormURLEncoded ...@@ -12,13 +12,17 @@ import Data.FormURLEncoded as FormURLEncoded
import Data.HTTP.Method (Method(..)) import Data.HTTP.Method (Method(..))
import Data.Maybe (Maybe(..)) import Data.Maybe (Maybe(..))
import Data.MediaType.Common (applicationFormURLEncoded, applicationJSON, multipartFormData) import Data.MediaType.Common (applicationFormURLEncoded, applicationJSON, multipartFormData)
import Data.Tuple (Tuple) import Data.Tuple (Tuple(..))
import DOM.Simple.Console (log2)
import Effect.Aff (Aff, throwError) import Effect.Aff (Aff, throwError)
import Effect.Class (liftEffect) import Effect.Class (liftEffect)
import Effect.Exception (error) import Effect.Exception (error)
import Milkis as Milkis
import Unsafe.Coerce (unsafeCoerce)
import Web.XHR.FormData as XHRFormData
import Gargantext.Prelude import Gargantext.Prelude
import Gargantext.Utils.Reactix as R2 import Gargantext.Utils.Reactix as R2
import Web.XHR.FormData as XHRFormData
type Token = String type Token = String
...@@ -26,7 +30,7 @@ type Token = String ...@@ -26,7 +30,7 @@ type Token = String
send :: forall a b. EncodeJson a => DecodeJson b => send :: forall a b. EncodeJson a => DecodeJson b =>
Method -> Maybe Token -> String -> Maybe a -> Aff b Method -> Maybe Token -> String -> Maybe a -> Aff b
send m mtoken url reqbody = do send m mtoken url reqbody = do
affResp <- request $ defaultRequest let req = defaultRequest
{ url = url { url = url
, responseFormat = ResponseFormat.json , responseFormat = ResponseFormat.json
, method = Left m , method = Left m
...@@ -38,6 +42,8 @@ send m mtoken url reqbody = do ...@@ -38,6 +42,8 @@ send m mtoken url reqbody = do
) mtoken ) mtoken
, content = (Json <<< encodeJson) <$> reqbody , content = (Json <<< encodeJson) <$> reqbody
} }
affResp <- request req
case mtoken of case mtoken of
Nothing -> pure unit Nothing -> pure unit
Just token -> liftEffect $ do Just token -> liftEffect $ do
...@@ -133,3 +139,4 @@ postMultipartFormData mtoken url body = do ...@@ -133,3 +139,4 @@ postMultipartFormData mtoken url body = do
case decodeJson json of case decodeJson json of
Left err -> throwError $ error $ "decodeJson affResp.body: " <> err Left err -> throwError $ error $ "decodeJson affResp.body: " <> err
Right b -> pure b Right b -> pure b
...@@ -202,7 +202,7 @@ sessionPath (R.Chart {chartType, listId, limit, tabType} i) = ...@@ -202,7 +202,7 @@ sessionPath (R.Chart {chartType, listId, limit, tabType} i) =
$ show chartType $ show chartType
<> "?ngramsType=" <> showTabType' tabType <> "?ngramsType=" <> showTabType' tabType
<> "&listType=MapTerm" -- <> show listId <> "&listType=MapTerm" -- <> show listId
<> "&listId=" <> show listId <> "&list=" <> show listId
where where
limitPath = case limit of limitPath = case limit of
Just li -> "&limit=" <> show li Just li -> "&limit=" <> show li
...@@ -213,7 +213,7 @@ sessionPath (R.ChartMD5 { chartType, listId, tabType } i) = ...@@ -213,7 +213,7 @@ sessionPath (R.ChartMD5 { chartType, listId, tabType } i) =
$ show chartType $ show chartType
<> "/md5?ngramsType=" <> showTabType' tabType <> "/md5?ngramsType=" <> showTabType' tabType
<> "&listType=GraphTerm" -- <> show listId <> "&listType=GraphTerm" -- <> show listId
<> "&listId=" <> show listId <> "&list=" <> show listId
-- sessionPath (R.NodeAPI (NodeContact s a i) i) = sessionPath $ "annuaire/" <> show a <> "/contact/" <> show i -- sessionPath (R.NodeAPI (NodeContact s a i) i) = sessionPath $ "annuaire/" <> show a <> "/contact/" <> show i
------- misc routing stuff ------- misc routing stuff
......
module Gargantext.Hooks.Loader where module Gargantext.Hooks.Loader where
import Gargantext.Prelude
import Data.Argonaut (class DecodeJson, class EncodeJson, decodeJson, encodeJson, (.:), (:=), (~>), jsonEmptyObject) import Data.Argonaut (class DecodeJson, class EncodeJson, decodeJson, encodeJson, (.:), (:=), (~>), jsonEmptyObject)
import Data.Argonaut.Core (stringify) import Data.Argonaut.Core (stringify)
import Data.Argonaut.Parser (jsonParser) import Data.Argonaut.Parser (jsonParser)
...@@ -9,13 +8,19 @@ import Data.Maybe (Maybe(..), isJust, maybe) ...@@ -9,13 +8,19 @@ import Data.Maybe (Maybe(..), isJust, maybe)
import Data.Tuple (fst) import Data.Tuple (fst)
import Data.Tuple.Nested ((/\)) import Data.Tuple.Nested ((/\))
import DOM.Simple.Console (log2) import DOM.Simple.Console (log2)
import Effect.Aff (Aff, launchAff_) import Effect.Aff (Aff, launchAff_, throwError)
import Effect.Class (liftEffect) import Effect.Class (liftEffect)
import Effect.Exception (error)
import Milkis as M
import Reactix as R import Reactix as R
import Web.Storage.Storage as WSS import Web.Storage.Storage as WSS
import Gargantext.Prelude
import Gargantext.Components.LoadingSpinner (loadingSpinner) import Gargantext.Components.LoadingSpinner (loadingSpinner)
import Gargantext.Ends (class ToUrl, toUrl)
import Gargantext.Utils as GU import Gargantext.Utils as GU
import Gargantext.Utils.CacheAPI as GUC
import Gargantext.Utils.Reactix as R2 import Gargantext.Utils.Reactix as R2
...@@ -48,8 +53,11 @@ useLoaderEffect path state@(state' /\ setState) loader = do ...@@ -48,8 +53,11 @@ useLoaderEffect path state@(state' /\ setState) loader = do
liftEffect $ setState $ const $ Just l liftEffect $ setState $ const $ Just l
type MD5 = String
newtype HashedResponse a = HashedResponse { newtype HashedResponse a = HashedResponse {
md5 :: String md5 :: MD5
, value :: a , value :: a
} }
...@@ -148,3 +156,70 @@ useCachedLoaderEffect { cacheEndpoint, keyFunc, loadRealData, path, state: state ...@@ -148,3 +156,70 @@ useCachedLoaderEffect { cacheEndpoint, keyFunc, loadRealData, path, state: state
where where
parse s = GU.mapLeft (\err -> "Error parsing serialised sessions:" <> show err) (jsonParser s) parse s = GU.mapLeft (\err -> "Error parsing serialised sessions:" <> show err) (jsonParser s)
decode j = GU.mapLeft (\err -> "Error decoding serialised sessions:" <> show err) (decodeJson j) decode j = GU.mapLeft (\err -> "Error decoding serialised sessions:" <> show err) (decodeJson j)
type LoaderWithCacheAPIProps path res ret = (
cacheEndpoint :: path -> Aff MD5
, handleResponse :: HashedResponse res -> ret
, mkRequest :: path -> GUC.Request
, path :: path
, renderer :: ret -> R.Element
)
useLoaderWithCacheAPI :: forall path res ret. Eq path => Show path => DecodeJson res =>
Record (LoaderWithCacheAPIProps path res ret)
-> R.Hooks R.Element
useLoaderWithCacheAPI { cacheEndpoint, handleResponse, mkRequest, path, renderer } = do
state <- R.useState' Nothing
useCachedAPILoaderEffect { cacheEndpoint
, handleResponse
, mkRequest
, path
, state }
pure $ maybe (loadingSpinner {}) renderer (fst state)
type LoaderWithCacheAPIEffectProps path res ret = (
cacheEndpoint :: path -> Aff MD5
, handleResponse :: HashedResponse res -> ret
, mkRequest :: path -> GUC.Request
, path :: path
, state :: R.State (Maybe ret)
)
useCachedAPILoaderEffect :: forall path res ret. Eq path => Show path => DecodeJson res =>
Record (LoaderWithCacheAPIEffectProps path res ret)
-> R.Hooks Unit
useCachedAPILoaderEffect { cacheEndpoint
, handleResponse
, mkRequest
, path
, state: state@(state' /\ setState) } = do
oPath <- R.useRef path
R.useEffect' $ do
if (R.readRef oPath == path) && (isJust state') then
pure unit
else do
R.setRef oPath path
let cacheName = "cache-api-loader"
let req = mkRequest path
let keyCache = "cached-api-md5-" <> (show path)
-- log2 "[useCachedLoader] mState" mState
launchAff_ $ do
cache <- GUC.openCache $ GUC.CacheName cacheName
-- TODO Parallelize?
hr@(HashedResponse { md5, value }) <- GUC.cachedJson cache req
cacheReal <- cacheEndpoint path
val <- if md5 == cacheReal then
pure hr
else do
_ <- GUC.delete cache req
hr@(HashedResponse { md5, value }) <- GUC.cachedJson cache req
if md5 == cacheReal then
pure hr
else
throwError $ error $ "Fetched clean cache but hashes don't match"
liftEffect $ do
setState $ const $ Just $ handleResponse hr
exports._makeRequest = function() {
return function(url) {
return function(options) {
return new Request(url, options);
}
}
}
exports._openCache = function(cacheName) {
return function() {
return caches.open(cacheName);
}
}
exports._delete = function(cache) {
return function(req) {
return function() {
cache.delete(req);
}
}
}
exports._add = function(cache) {
return function(req) {
return function() {
return cache.add(req);
}
}
}
exports._match = function(cache) {
return function(req) {
return function() {
return cache.match(req);
}
}
}
module Gargantext.Utils.CacheAPI where
import Control.Monad.Except (runExcept)
import Control.Promise (Promise, toAffE)
import Data.Argonaut (class DecodeJson, decodeJson, class EncodeJson, encodeJson, (:=), (~>), (.:), fromString)
import Data.Either (Either(..))
import Data.Function.Uncurried (Fn3)
import Data.Maybe (Maybe(..))
import Data.Tuple (Tuple(..))
import DOM.Simple.Console (log2)
import Effect (Effect)
import Effect.Aff (Aff, throwError)
import Effect.Aff.Compat (EffectFnAff, fromEffectFnAff)
import Effect.Class (liftEffect)
import Effect.Exception (error)
import Foreign as F
import Foreign.Object as O
import Milkis as M
import Type.Row (class Union)
import Gargantext.Prelude
import Gargantext.Ends (class ToUrl, toUrl)
import Gargantext.Sessions (Session(..))
get :: forall a p. DecodeJson a => ToUrl Session p => Cache -> Session -> p -> Aff a
get cache session p = do
let req = makeGetRequest session p
res <- cached cache req
j <- M.json res
case decodeJson (F.unsafeFromForeign j) of
Left err -> throwError $ error $ "decodeJson affResp.body: " <> err
Right b -> pure b
foreign import data Cache :: Type
foreign import data Request :: Type
newtype CacheName = CacheName String
type Token = String
makeRequest :: forall options trash. Union options trash M.Options =>
M.URL -> { method :: M.Method, headers :: M.Headers | options } -> Request
makeRequest url options = _makeRequest url options
makeTokenRequest :: forall options trash. Union options trash M.Options =>
M.URL -> Maybe Token -> { method :: M.Method, headers :: M.Headers | options } -> Request
makeTokenRequest url mToken options = case mToken of
Nothing -> makeRequest url $ options { headers = mkHeaders O.empty }
Just t -> makeRequest url $ options { headers = mkHeaders $ O.singleton "Authorization" $ "Bearer " <> t }
where
defaultOptions = O.fromFoldable [ Tuple "Accept" "application/json"
, Tuple "Content-Type" "application/json" ]
mkHeaders t = O.unions [ options.headers, defaultOptions, t ]
makeGetRequest :: forall p. ToUrl Session p => Session -> p -> Request
makeGetRequest session@(Session { token }) p = makeTokenRequest url (Just token) { method, headers: O.empty }
where
method = M.getMethod
url = M.URL $ toUrl session p
openCache :: CacheName -> Aff Cache
openCache (CacheName cacheName) = toAffE $ _openCache cacheName
add :: Cache -> Request -> Aff Unit
add cache req = toAffE $ _add cache req
match :: Cache -> Request -> Aff (Maybe M.Response)
match cache req = do
res <- toAffE $ _match cache req
case runExcept $ F.readNullOrUndefined res of
Left err -> throwError $ error $ show err
Right v -> pure $ F.unsafeFromForeign <$> v
cached :: Cache -> Request -> Aff M.Response
cached cache req = do
mRes <- match cache req
case mRes of
Just res -> do
liftEffect $ log2 "[cached] cache hit" req
pure res
Nothing -> do
liftEffect $ log2 "[cached] cache miss" req
_ <- add cache req
mResFresh <- match cache req
case mResFresh of
Just res -> pure res
Nothing -> throwError $ error $ "Cannot add to cache"
cachedJson :: forall a. DecodeJson a => Cache -> Request -> Aff a
cachedJson cache req = do
res <- cached cache req
liftEffect $ do
log2 "[cachedJson] res" res
j <- M.json res
case decodeJson (F.unsafeFromForeign j) of
Left err -> throwError $ error $ "decodeJson affResp.body: " <> err
Right b -> pure b
delete :: Cache -> Request -> Aff Unit
delete cache req = toAffE $ _delete cache req
foreign import _makeRequest :: forall options trash. Union options trash M.Options =>
M.URL -> { method :: M.Method, headers :: M.Headers | options } -> Request
foreign import _openCache :: String -> Effect (Promise Cache)
foreign import _delete :: Cache -> Request -> Effect (Promise Unit)
foreign import _add :: Cache -> Request -> Effect (Promise Unit)
foreign import _match :: Cache -> Request -> Effect (Promise F.Foreign)
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment