From a54275ba76f1436bcd2d1de49d3ed1f7c6bc94d7 Mon Sep 17 00:00:00 2001 From: Tim Steinbach Date: Thu, 18 Feb 2021 15:08:03 -0500 Subject: ripgrep: Add installCheckPhase (#113621) * ripgrep: Add installCheckPhase Convert test removed in dd63561bcbe5f7b86063c7c6e80fca5af487d801 to an installCheckPhase * Update pkgs/tools/text/ripgrep/default.nix Co-authored-by: Sandro --- pkgs/tools/text/ripgrep/default.nix | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'pkgs/tools/text/ripgrep') diff --git a/pkgs/tools/text/ripgrep/default.nix b/pkgs/tools/text/ripgrep/default.nix index 1d9f4aa4bdb..04f0cb59c03 100644 --- a/pkgs/tools/text/ripgrep/default.nix +++ b/pkgs/tools/text/ripgrep/default.nix @@ -37,6 +37,14 @@ rustPlatform.buildRustPackage rec { installShellCompletion --zsh complete/_rg ''; + doInstallCheck = true; + installCheckPhase = '' + file="$(mktemp)" + echo "abc\nbcd\ncde" > "$file" + $out/bin/rg -N 'bcd' "$file" + $out/bin/rg -N 'cd' "$file" + ''; + meta = with lib; { description = "A utility that combines the usability of The Silver Searcher with the raw speed of grep"; homepage = "https://github.com/BurntSushi/ripgrep"; -- cgit 1.4.1