forked from Ali-Hill/plutus-apps
-
Notifications
You must be signed in to change notification settings - Fork 0
/
default.nix
67 lines (54 loc) · 2.5 KB
/
default.nix
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
########################################################################
# default.nix -- The top-level nix build file for Plutus apps.
#
# This file defines various attributes that are used for building and
# developing Plutus apps.
#
########################################################################
{ system ? builtins.currentSystem
, crossSystem ? null
, config ? { }
, sourcesOverride ? { }
, sources ? import ./nix/sources.nix { inherit system; } // sourcesOverride
, haskellNix ? import sources.haskell-nix {
pkgs = import sources.nixpkgs { inherit system; };
sourcesOverride = {
hackage = sources.hackage-nix;
stackage = sources.stackage-nix;
};
}
, packages ? import ./nix { inherit system sources crossSystem config sourcesOverride haskellNix enableHaskellProfiling; }
# Whether to build our Haskell packages (and their dependencies) with profiling enabled.
, enableHaskellProfiling ? false
}:
let
inherit (packages) pkgs plutus-apps;
inherit (plutus-apps) haskell;
in
rec {
inherit pkgs plutus-apps;
inherit (haskell.packages.plutus-pab-executables.components.exes)
plutus-pab-examples
plutus-uniswap;
webCommon = pkgs.callPackage sources.web-common { inherit (plutus-apps.lib) gitignore-nix; };
plutus-use-cases = pkgs.callPackage ./plutus-use-cases {
inherit haskell;
};
pab-cli = plutus-apps.haskell.packages.plutus-pab-executables.components.exes.pab-cli;
plutus-chain-index = plutus-apps.haskell.packages.plutus-chain-index.components.exes.plutus-chain-index;
marconi = plutus-apps.haskell.packages.marconi.components.exes.marconi;
marconi-mamba = plutus-apps.haskell.packages.marconi-mamba.components.exes.marconi-mamba;
create-script-context = plutus-apps.haskell.packages.plutus-example.components.exes.create-script-context;
tests = import ./nix/tests/default.nix {
inherit pkgs docs;
inherit (plutus-apps.lib) gitignore-nix;
inherit (plutus-apps) fixStylishHaskell fix-purs-tidy fixPngOptimization fixCabalFmt;
src = ./.;
};
docs = import ./nix/docs.nix { inherit pkgs plutus-apps; };
# This builds a vscode devcontainer that can be used with the plutus-starter project (or probably the plutus project itself).
devcontainer = import ./nix/devcontainer/plutus-devcontainer.nix { inherit pkgs plutus-apps; };
build-and-push-devcontainer-script = import ./nix/devcontainer/deploy/default.nix { inherit pkgs plutus-apps; };
# Packages needed for the bitte deployment
bitte-packages = import ./bitte { inherit docs pkgs; };
}