1{
2 lib,
3 fetchCrate,
4 rustPlatform,
5 versionCheckHook,
6 nix-update-script,
7}:
8
9rustPlatform.buildRustPackage (finalAttrs: {
10 pname = "jsonschema-cli";
11 version = "0.32.0";
12
13 src = fetchCrate {
14 pname = "jsonschema-cli";
15 inherit (finalAttrs) version;
16 hash = "sha256-ZcavZSHf2eT65f7HbtZmD2mYUtrXEL/l1opXCvdn1O0=";
17 };
18
19 cargoHash = "sha256-ivD1dvz2xxNei77Dq6myE4zivWD8LZoEqq8E7QhgP9s=";
20
21 nativeInstallCheckInputs = [
22 versionCheckHook
23 ];
24 doInstallCheck = true;
25 versionCheckProgramArg = "--version";
26
27 passthru.updateScript = nix-update-script { };
28
29 meta = {
30 description = "Fast command-line tool for JSON Schema validation";
31 homepage = "https://github.com/Stranger6667/jsonschema";
32 changelog = "https://github.com/Stranger6667/jsonschema/releases/tag/rust-v${finalAttrs.version}";
33 license = lib.licenses.mit;
34 maintainers = with lib.maintainers; [
35 kachick
36 ];
37 mainProgram = "jsonschema-cli";
38 };
39})