Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at devShellTools-shell 47 lines 1.0 kB view raw
1{ 2 lib, 3 fetchFromGitHub, 4 rustPlatform, 5 versionCheckHook, 6 nix-update-script, 7}: 8rustPlatform.buildRustPackage (finalAttrs: { 9 pname = "iwe"; 10 version = "0.0.33"; 11 12 src = fetchFromGitHub { 13 owner = "iwe-org"; 14 repo = "iwe"; 15 tag = "iwe-v${finalAttrs.version}"; 16 hash = "sha256-PjonpAyq6FPJs5mo4W3z9yIVU8auGGtTrK/GBxMcPbk="; 17 }; 18 19 cargoHash = "sha256-EfoDpa2hN9W2unci4rIi4gjlJV2NzdU77FbOW0OTu2c="; 20 21 cargoBuildFlags = [ 22 "--package=iwe" 23 "--package=iwes" 24 ]; 25 26 nativeInstallCheckInputs = [ versionCheckHook ]; 27 versionCheckProgramArg = "--version"; 28 doInstallCheck = true; 29 30 passthru.updateScript = nix-update-script { 31 extraArgs = [ 32 "--version-regex" 33 "^iwe-v(.*)$" 34 ]; 35 }; 36 37 meta = { 38 description = "Personal knowledge management system (editor plugin & command line utility)"; 39 homepage = "https://iwe.md/"; 40 license = lib.licenses.asl20; 41 maintainers = with lib.maintainers; [ 42 phrmendes 43 HeitorAugustoLN 44 ]; 45 mainProgram = "iwe"; 46 }; 47})