depot/third_party/nixpkgs/pkgs/development/interpreters/expr/default.nix
Default email e7ec2969af Project import generated by Copybara.
GitOrigin-RevId: 9b19f5e77dd906cb52dade0b7bd280339d2a1f3d
2024-01-13 09:15:51 +01:00

35 lines
795 B
Nix

{ lib
, buildGoModule
, fetchFromGitHub
}:
buildGoModule rec {
pname = "expr";
version = "1.15.8";
src = fetchFromGitHub {
owner = "antonmedv";
repo = "expr";
rev = "v${version}";
hash = "sha256-leZEP6RJv136z/bNc1S74tw+JQ3QD7NCMbo/Wo7q0ek=";
};
sourceRoot = "${src.name}/repl";
vendorHash = "sha256-Rs2tlno0vJo8FSdnnk3cxQCCxdByQD1jRzmePzMMfvs=";
ldflags = [ "-s" "-w" ];
postInstall = ''
mv $out/bin/{repl,expr}
'';
meta = with lib; {
description = "Expression language and expression evaluation for Go";
homepage = "https://github.com/antonmedv/expr";
changelog = "https://github.com/antonmedv/expr/releases/tag/${src.rev}";
license = licenses.mit;
maintainers = with maintainers; [ figsoda ];
mainProgram = "expr";
};
}