depot/third_party/nixpkgs/pkgs/development/tools/rust/rust-script/default.nix

27 lines
767 B
Nix
Raw Normal View History

{ lib, rustPlatform, fetchFromGitHub }:
rustPlatform.buildRustPackage rec {
pname = "rust-script";
version = "0.25.0";
src = fetchFromGitHub {
owner = "fornwall";
repo = pname;
rev = version;
sha256 = "sha256-oY971/+3PizyOtKSXeyHUlC+Rf+qS+Zf5Ls+OL6rIgE=";
};
cargoSha256 = "sha256-NtYmJS9SBNZkF5hv5IcPzk6DxYLAu1/nBexahdjUYgY=";
# tests require network access
doCheck = false;
meta = with lib; {
description = "Run Rust files and expressions as scripts without any setup or compilation step";
homepage = "https://rust-script.org";
changelog = "https://github.com/fornwall/rust-script/releases/tag/${version}";
license = with licenses; [ mit /* or */ asl20 ];
maintainers = with maintainers; [ figsoda ];
};
}