about summary refs log tree commit diff
path: root/pkgs/tools/text/agrep
diff options
context:
space:
mode:
authorc74d <8573dd@gmail.com>2016-11-05 08:51:49 +0000
committerc74d <8573dd@gmail.com>2016-11-05 08:55:29 +0000
commit0033f6076ee5c462722bf6077c40ff7949ae6020 (patch)
tree01d0788c912d943012c996380bc2cf9b4e3cf4bf /pkgs/tools/text/agrep
parent321e2a915375231d48fb41493266cdf2095330a9 (diff)
downloadnixlib-0033f6076ee5c462722bf6077c40ff7949ae6020.tar
nixlib-0033f6076ee5c462722bf6077c40ff7949ae6020.tar.gz
nixlib-0033f6076ee5c462722bf6077c40ff7949ae6020.tar.bz2
nixlib-0033f6076ee5c462722bf6077c40ff7949ae6020.tar.lz
nixlib-0033f6076ee5c462722bf6077c40ff7949ae6020.tar.xz
nixlib-0033f6076ee5c462722bf6077c40ff7949ae6020.tar.zst
nixlib-0033f6076ee5c462722bf6077c40ff7949ae6020.zip
agrep: init at 3.41.5
In category `tools`, subcategory `text`, add a package definition for
the program [`agrep`] [1] — "Approximate `grep` for fast fuzzy string
searching".

I have tested this patch per nixpkgs manual section 11.1 ("Making
patches").

[1]: <https://www.tgries.de/agrep/>
Diffstat (limited to 'pkgs/tools/text/agrep')
-rw-r--r--pkgs/tools/text/agrep/default.nix26
1 files changed, 26 insertions, 0 deletions
diff --git a/pkgs/tools/text/agrep/default.nix b/pkgs/tools/text/agrep/default.nix
new file mode 100644
index 000000000000..81c098408482
--- /dev/null
+++ b/pkgs/tools/text/agrep/default.nix
@@ -0,0 +1,26 @@
+{ stdenv, fetchFromGitHub }:
+
+stdenv.mkDerivation rec {
+  name = "agrep-${version}";
+  version = "3.41.5";
+
+  src = fetchFromGitHub {
+    owner = "Wikinaut";
+    repo = "agrep";
+    # This repository has numbered versions, but not Git tags.
+    rev = "eef20411d605d9d17ead07a0ade75046f2728e21";
+    sha256 = "14addnwspdf2mxpqyrw8b84bb2257y43g5ccy4ipgrr91fmxq2sk";
+  };
+
+  installPhase = ''
+    install -Dm 555 agrep -t "$out/bin"
+    install -Dm 444 docs/* -t "$out/doc"
+  '';
+
+  meta = {
+    description = "Approximate grep for fast fuzzy string searching";
+    homepage = "https://www.tgries.de/agrep/";
+    license = stdenv.lib.licenses.isc;
+    platforms = stdenv.lib.platforms.linux;
+  };
+}