From 577645d09fe5bae5f3a5244ba12e3ec13b488a6e Mon Sep 17 00:00:00 2001 From: Thiago Kenji Okada Date: Mon, 25 Jan 2021 11:36:46 -0300 Subject: [PATCH] dart: add some assertions --- pkgs/development/interpreters/dart/default.nix | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/pkgs/development/interpreters/dart/default.nix b/pkgs/development/interpreters/dart/default.nix index cf92e723a612..5fb180201b96 100644 --- a/pkgs/development/interpreters/dart/default.nix +++ b/pkgs/development/interpreters/dart/default.nix @@ -9,6 +9,9 @@ x86_64 = "x64"; i686 = "ia32"; aarch64 = "arm64"; + # Make sure that if the user overrides version parameter they're + # also need to override sources, to avoid mistakes + version = "2.10.5"; in { "${version}-x86_64-darwin" = fetchurl { @@ -30,6 +33,9 @@ } }: +assert version != null && version != ""; +assert sources != null && (builtins.isAttrs sources); + stdenv.mkDerivation { pname = "dart"; inherit version;