2020-12-09 16:20:24 +03:00
|
|
|
{ sources ? import ./nix/sources.nix
|
2021-07-13 11:53:53 +03:00
|
|
|
, haskellNix ? import sources.haskellNix { }
|
|
|
|
, pkgs ? import haskellNix.sources.nixpkgs-2105 haskellNix.nixpkgsArgs
|
2020-12-09 16:20:24 +03:00
|
|
|
}:
|
2021-07-13 11:53:53 +03:00
|
|
|
let
|
|
|
|
hsPkgs = pkgs.haskell-nix.cabalProject {
|
|
|
|
src = pkgs.haskell-nix.haskellLib.cleanGit {
|
|
|
|
name = "octopod";
|
|
|
|
src = ./.;
|
2020-12-11 16:31:46 +03:00
|
|
|
};
|
2021-07-13 11:53:53 +03:00
|
|
|
index-state = "2021-07-02T00:00:00Z";
|
|
|
|
compiler-nix-name = "ghc8105";
|
|
|
|
};
|
|
|
|
in
|
|
|
|
hsPkgs // {
|
|
|
|
octopod-frontend-pretty =
|
|
|
|
pkgs.runCommand "octopod-frontend-pretty"
|
|
|
|
{ } ''
|
|
|
|
mkdir $out
|
|
|
|
cp ${./octopod-frontend/index.html} $out/index.html
|
|
|
|
cp ${hsPkgs.projectCross.ghcjs.hsPkgs.octopod-frontend.components.exes.frontend}/bin/frontend.jsexe/all.js $out/all.js
|
|
|
|
'';
|
|
|
|
}
|