anchor.diff: -{ stdenv, lib, buildGoModule, fetchFromGitHub, makeWrapper, coreutils
  -, runCommand, runtimeShell, writeText, terraform-providers, fetchpatch }:
  +{ stdenv
  +, lib
  +, buildGoModule
  +, fetchFromGitHub
  +, makeWrapper
  +, coreutils
  +, runCommand
  +, runtimeShell
  +, writeText
  +, terraform-providers
  +, fetchpatch
  +}:
   
   let
     generic = { version, sha256, vendorSha256 ? null, ... }@attrs:
       let attrs' = builtins.removeAttrs attrs [ "version" "sha256" "vendorSha256" ];
  -    in buildGoModule ({
  +    in
  +    buildGoModule ({
         name = "terraform-${version}";
   
         inherit vendorSha256;
  
positive.code: 
              inherit passthru;
            });
      in withPlugins (_: [ ]);
  
    plugins = removeAttrs terraform-providers [
      "override"
      "overrideDerivation"
      "recurseForDerivations"
    ];
  in rec {
    terraform_0_12 = pluggable (generic {
      version = "0.12.31";
      sha256 = "03p698xdbk5gj0f9v8v1fpd74zng3948dyy4f2hv7zgks9hid7fg";
      patches = [
          ./provider-path.patch
          (fetchpatch {
              name = "fix-mac-mojave-crashes.patch";
              url = "https://github.com/hashicorp/terraform/commit/cd65b28da051174a13ac76e54b7bb95d3051255c.patch";
              sha256 = "1k70kk4hli72x8gza6fy3vpckdm3sf881w61fmssrah3hgmfmbrs";
          }) ];
      passthru = { inherit plugins; };
    });
  
  
negative.code:   # file pattern and if the plugin is not found it will try to download it
    # from the Internet. With sandboxing enable this test will fail if that is
    # the case.
    terraform_plugins_test =
      let
        mainTf = writeText "main.tf" ''
          resource "random_id" "test" {}
        '';
        terraform = terraform_0_12.withPlugins (p: [ p.random ]);
        test =
          runCommand "terraform-plugin-test" { buildInputs = [ terraform ]; } ''
            set -e
            # make it fail outside of sandbox
            export HTTP_PROXY=http://127.0.0.1:0 HTTPS_PROXY=https://127.0.0.1:0
            cp ${mainTf} main.tf
            terraform init
            touch $out
          '';
      in
      test;
  
  }
  