Unverified Commit 34a9dfb7 authored by Gaétan Lepage's avatar Gaétan Lepage Committed by GitHub
Browse files

regolith: init at 1.5.1 (#374961)

parents edbc1dbf e48e51ee
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -1843,6 +1843,12 @@
    githubId = 53097078;
    name = "AJ Reifsnyder";
  };
  arexon = {
    email = "arexonreal@gmail.com";
    github = "arexon";
    githubId = 65680034;
    name = "arexon";
  };
  arezvov = {
    email = "alex@rezvov.ru";
    github = "arezvov";
+43 −0
Original line number Diff line number Diff line
{
  lib,
  buildGoModule,
  fetchFromGitHub,
  nix-update-script,
  versionCheckHook,
}:
buildGoModule rec {
  pname = "regolith";
  version = "1.5.1";

  src = fetchFromGitHub {
    owner = "Bedrock-OSS";
    repo = "regolith";
    tag = version;
    hash = "sha256-gTEQ2hu581tD1I/3iLHzE/2nekAG49/M6V6QeqPhYsA=";
  };

  # Requires network access.
  doCheck = false;

  vendorHash = "sha256-+4J4Z7lhbAphi6WUEJN9pzNXf6ROUKqN4NdKI2sQSW0=";

  ldflags = [
    "-X main.buildSource=nix"
    "-X main.version=${version}"
  ];

  nativeInstallCheckInputs = [ versionCheckHook ];
  versionCheckProgramArg = "--version";
  doInstallCheck = true;

  passthru.updateScript = nix-update-script { };

  meta = {
    description = "Add-on Compiler for the Bedrock Edition of Minecraft";
    homepage = "https://github.com/Bedrock-OSS/regolith";
    changelog = "https://github.com/Bedrock-OSS/regolith/releases/tag/${version}";
    license = lib.licenses.mit;
    maintainers = with lib.maintainers; [ arexon ];
    mainProgram = "regolith";
  };
}