# This file was generated by GoReleaser. DO NOT EDIT.
# vim: set ft=nix ts=2 sw=2 sts=2 et sta
{
system ? builtins.currentSystem
, pkgs
, lib
, fetchurl
, installShellFiles
}:
let
  shaMap = {
    i686-linux = "0000000000000000000000000000000000000000000000000000";
    x86_64-linux = "0000000000000000000000000000000000000000000000000000";
    aarch64-linux = "0000000000000000000000000000000000000000000000000000";
    x86_64-darwin = "0000000000000000000000000000000000000000000000000000";
    aarch64-darwin = "0000000000000000000000000000000000000000000000000000";
  };

  urlMap = {
    i686-linux = "https://dummyhost/download/v1.2.1/foo_linux_386.tar.gz";
    x86_64-linux = "https://dummyhost/download/v1.2.1/foo_linux_amd64v1.tar.gz";
    aarch64-linux = "https://dummyhost/download/v1.2.1/foo_linux_arm64.tar.gz";
    x86_64-darwin = "https://dummyhost/download/v1.2.1/foo_darwin_all.tar.gz";
    aarch64-darwin = "https://dummyhost/download/v1.2.1/foo_darwin_all.tar.gz";
  };
in
pkgs.stdenv.mkDerivation {
  pname = "unibin-replaces";
  version = "1.2.1";
  src = fetchurl {
    url = urlMap.${system};
    sha256 = shaMap.${system};
  };

  sourceRoot = ".";

  nativeBuildInputs = [ installShellFiles ];

  installPhase = ''
    mkdir -p $out/bin
    cp -vr ./foo $out/bin/foo
  '';

  system = system;

  meta = {
    description = "my test";
    homepage = "https://goreleaser.com";
    license = lib.licenses.mit;

    sourceProvenance = [ lib.sourceTypes.binaryNativeCode ];

    platforms = [
      "aarch64-darwin"
      "aarch64-linux"
      "i686-linux"
      "x86_64-darwin"
      "x86_64-linux"
    ];
  };
}
