Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at devShellTools-shell 48 lines 1.1 kB view raw
1{ 2 lib, 3 rustPlatform, 4 fetchFromGitHub, 5 nix-update-script, 6 versionCheckHook, 7}: 8 9rustPlatform.buildRustPackage (finalAttrs: { 10 pname = "typstyle"; 11 version = "0.13.16"; 12 13 src = fetchFromGitHub { 14 owner = "typstyle-rs"; 15 repo = "typstyle"; 16 tag = "v${finalAttrs.version}"; 17 hash = "sha256-dfw1jyPNZ0LDEZ+pbJt9DWKa4aBlFCAZIgKrZK+AmJw="; 18 }; 19 20 cargoHash = "sha256-Eg8i+vsBp0BuxxBWXZisVKiGge25UKfxoK/3Knk+LsU="; 21 22 # Disabling tests requiring network access 23 checkFlags = [ 24 "--skip=e2e" 25 ]; 26 27 nativeInstallCheckInputs = [ 28 versionCheckHook 29 ]; 30 versionCheckProgramArg = "--version"; 31 doInstallCheck = true; 32 33 passthru = { 34 updateScript = nix-update-script { }; 35 }; 36 37 meta = { 38 changelog = "https://github.com/typstyle-rs/typstyle/blob/${finalAttrs.src.tag}/CHANGELOG.md"; 39 description = "Format your typst source code"; 40 homepage = "https://github.com/typstyle-rs/typstyle"; 41 license = lib.licenses.asl20; 42 mainProgram = "typstyle"; 43 maintainers = with lib.maintainers; [ 44 drupol 45 prince213 46 ]; 47 }; 48})