Commit 92e83dd9 authored by Ethan Carter Edwards's avatar Ethan Carter Edwards Committed by github-actions[bot]
Browse files

json-schema-catalog-rs: add versionCheckHook

(cherry picked from commit 72eaf394)
parent b8815f18
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -4,6 +4,7 @@
  lib,
  nix-update-script,
  rustPlatform,
  versionCheckHook,
}:

rustPlatform.buildRustPackage (finalAttrs: {
@@ -19,6 +20,11 @@ rustPlatform.buildRustPackage (finalAttrs: {

  cargoHash = "sha256-YI2LN2DBzC1B5wCZOrGAZi/hkKHoAm6xLkdJ+8DDFo8=";

  doInstallCheck = true;
  nativeInstallCheckInputs = [ versionCheckHook ];
  versionCheckProgram = "${placeholder "out"}/bin/json-schema-catalog";
  versionCheckProgramArg = "--version";

  passthru = {
    tests = {
      run = callPackage ./test-run.nix { json-schema-catalog-rs = finalAttrs.finalPackage; };