Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion .hlint.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
- {name: unsafePerformIO, within: [PlutusPrelude, Language.PlutusCore.Generators.Internal.Entity, Language.PlutusCore.Constant.Dynamic.Call, Language.PlutusCore.Constant.Dynamic.Emit, Language.PlutusCore.Constant.Dynamic.Instances, Language.PlutusCore.StdLib.Type, Language.PlutusTx.Plugin, Language.PlutusTx.Evaluation]}
- {name: error}
- {name: undefined, within: [Language.PlutusCore.Constant.Apply, Language.PlutusTx.Lift.Class, Language.PlutusTx.Lift.Instances]}
- {name: fromJust, within: [Language.PlutusTx.Lift, Spec.Lib]}
- {name: fromJust, within: [Language.PlutusTx.Lift, Spec.Lib, Ledger.Scripts]}
- {name: foldl, within: []}
- {name: traceShowId, within: []} # for debugging only, should not be merged to master

Expand All @@ -22,9 +22,12 @@
- ignore: {name: Use newtype instead of data, within: [Tutorial.Emulator]}
# this is rarely an improvement, also ignored in cardano
- ignore: {name: Move brackets to avoid $}
# this is often worse
- ignore: {name: Use <$>}
# this aids clarity since you can name the parameters
- ignore: {name: Avoid lambda}
- ignore: {name: Avoid lambda using `infix`}
- ignore: {name: Replace case with fromMaybe}
# whether this is better is very variable
- ignore: {name: Use infix}
# hlint can't handle typed TH: https://github.com/haskell-suite/haskell-src-exts/issues/383
Expand Down
25 changes: 12 additions & 13 deletions default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,9 @@
########################################################################

{ system ? builtins.currentSystem
, crossSystem ? builtins.currentSystem
# The nixpkgs configuration file
, config ? { allowUnfreePredicate = (import ./lib.nix {}).unfreePredicate;
packageOverrides = (import ./lib.nix {}).packageOverrides;
}
, config ? { allowUnfreePredicate = (import ./lib.nix {}).unfreePredicate; }

# Use a pinned version nixpkgs.
, pkgs ? (import ./lib.nix { inherit config system; }).pkgs
Expand All @@ -40,19 +39,12 @@
# Profiling slows down performance by 50% so we don't enable it by default.
, enableProfiling ? false

# Enable separation of build/check derivations.
, enableSplitCheck ? true

# Keeps the debug information for all haskell packages.
, enableDebugging ? false

# Build (but don't run) benchmarks for all local packages.
, enableBenchmarks ? true

# Overrides all nix derivations to add build timing information in
# their build output.
, enablePhaseMetrics ? true

# Overrides all nix derivations to add haddock hydra output.
, enableHaddockHydra ? true

Expand Down Expand Up @@ -132,9 +124,13 @@ let
# so we make sure it uses the same one.
pkgsGenerated = import ./pkgs { inherit pkgs; };
in self.callPackage localLib.iohkNix.haskellPackages {
inherit forceDontCheck enableProfiling enablePhaseMetrics
inherit forceDontCheck enableProfiling
enableHaddockHydra enableBenchmarks fasterBuild enableDebugging
enableSplitCheck customOverlays pkgsGenerated;
customOverlays pkgsGenerated;
# Broken on vanilla 19.09, require the IOHK fork. Will be abandoned when
# we go to haskell.nix anyway.
enablePhaseMetrics = false;
enableSplitCheck = false;

filter = localLib.isPlutus;
filterOverrides = {
Expand Down Expand Up @@ -472,7 +468,10 @@ let
pkgs.nodejs-10_x
pkgs.nodePackages_10_x.node-gyp
pkgs.yarn
pkgs.yarn2nix
# yarn2nix won't seem to build on hydra, see
# https://github.com/moretea/yarn2nix/pull/103
# I can't figure out how to fix this...
#pkgs.yarn2nix-moretea.yarn2nix
easyPS.purs
easyPS.psc-package
easyPS.spago
Expand Down
6 changes: 3 additions & 3 deletions iohk-nix.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"url": "https://github.com/input-output-hk/iohk-nix",
"rev": "3e85f93893770ea30055de860d3f664dbe913f7d",
"date": "2019-06-10T09:30:54+00:00",
"sha256": "024misnixil0scn6z9y353n1c1vksr40m99zp0hxndxxdxmix011",
"rev": "29bbc658a3dcae5c17065b572c442dd7a9379c6e",
"date": "2019-10-22T16:03:42+00:00",
"sha256": "1baqj866ms1q0iwp9lvpipb0jn9d570mapy1jj4npql6zd5015hc",
"fetchSubmodules": false
}
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
{-# LANGUAGE KindSignatures #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RankNTypes #-}
{-# LANGUAGE TypeApplications #-}

module Language.PlutusCore.Constant.Typed
( TypeScheme (..)
Expand Down
1 change: 0 additions & 1 deletion language-plutus-core/src/Language/PlutusCore/MkPlc.hs
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE FunctionalDependencies #-}
{-# LANGUAGE LambdaCase #-}
{-# LANGUAGE MultiParamTypeClasses #-}

module Language.PlutusCore.MkPlc ( TermLike (..)
, VarDecl (..)
Expand Down
21 changes: 5 additions & 16 deletions lib.nix
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,11 @@ let
in builtins.fetchTarball {
url = "${spec.url}/archive/${spec.rev}.tar.gz";
inherit (spec) sha256;
}) { inherit system config; };
}) { inherit system config; nixpkgsJsonOverride = ./nixpkgs.json; };

# nixpkgs can be overridden for debugging purposes by setting
# NIX_PATH=custom_nixpkgs=/path/to/nixpkgs
pkgs = iohkNix.pkgs;
pkgs = iohkNix.getPkgs { extraOverlays = [ (import ./nix/overlays/musl.nix) ]; };
nixpkgs = iohkNix.nixpkgs;
lib = pkgs.lib;
getPackages = iohkNix.getPackages;
Expand Down Expand Up @@ -54,19 +54,9 @@ let

regeneratePackages = iohkNix.stack2nix.regeneratePackages { hackageSnapshot = "2019-09-12T00:02:45Z"; };

unfreePredicate = pkg: (builtins.parseDrvName pkg.name).name == "kindlegen";

packageOverrides = pkgs: {
python36 = pkgs.python36.override {
packageOverrides = self: super: {
cython = super.cython.overridePythonAttrs (old: rec {
# TODO Cython tests for unknown reason hang with musl. Remove when that's fixed.
# See https://github.com/nh2/static-haskell-nix/issues/6#issuecomment-421852854
doCheck = false;
});
};
};
};
unfreePredicate = pkg:
if pkg ? name then (builtins.parseDrvName pkg.name).name == "kindlegen"
else if pkg ? pname then pkg.pname == "kindlegen" else false;

comp = f: g: (v: f(g v));

Expand All @@ -80,7 +70,6 @@ in lib // {
plutusPkgList
regeneratePackages
unfreePredicate
packageOverrides
nixpkgs
pkgs
comp;
Expand Down
5 changes: 1 addition & 4 deletions marlowe-playground-client/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,6 @@
"webpack-dev-server": "^3.1.10",
"xhr2": "^0.1.4"
},
"resolutions": {
"events": "2.1.0",
"execa": "<=2.0.0"
},
"resolutions": { },
"license": "Apache-2.0"
}
Loading