From 084c8644ff946e555f31c888addd454887ebf248 Mon Sep 17 00:00:00 2001 From: Matthias Beyer Date: Sat, 30 Mar 2019 23:55:12 +0100 Subject: [PATCH] vimpager: Init at 2.06 and master (#58580) * vimpager: Init at 2.06 and master Adding a package vimpager-latest because the last release was 2015. Signed-off-by: Matthias Beyer * fixup! vimpager: Init at 2.06 and master --- pkgs/tools/misc/vimpager/build.nix | 39 ++++++++++++++++++++++++++++ pkgs/tools/misc/vimpager/default.nix | 6 +++++ pkgs/tools/misc/vimpager/latest.nix | 7 +++++ pkgs/top-level/all-packages.nix | 3 +++ 4 files changed, 55 insertions(+) create mode 100644 pkgs/tools/misc/vimpager/build.nix create mode 100644 pkgs/tools/misc/vimpager/default.nix create mode 100644 pkgs/tools/misc/vimpager/latest.nix diff --git a/pkgs/tools/misc/vimpager/build.nix b/pkgs/tools/misc/vimpager/build.nix new file mode 100644 index 000000000000..e9733c7ef799 --- /dev/null +++ b/pkgs/tools/misc/vimpager/build.nix @@ -0,0 +1,39 @@ +{ stdenv +, fetchFromGitHub +, coreutils +, sharutils +, version +, sha256 +}: + +stdenv.mkDerivation rec { + inherit version; + name = "vimpager-${version}"; + + src = fetchFromGitHub { + inherit sha256; + + owner = "rkitover"; + repo = "vimpager"; + rev = "${version}"; + }; + + buildInputs = [ coreutils sharutils ]; # for uuencode + + makeFlags = [ + "PREFIX=$(out)" + ]; + + buildPhase = '' + sed -i 's,/bin/cat,${coreutils}/bin/cat,g' vimpager + make + ''; + + + meta = with stdenv.lib; { + description = "Use Vim as PAGER"; + homepage = "https://www.vim.org/scripts/script.php?script_id = 1723"; + license = with licenses; [ bsd2 mit vim ]; + platforms = platforms.unix; + }; +} diff --git a/pkgs/tools/misc/vimpager/default.nix b/pkgs/tools/misc/vimpager/default.nix new file mode 100644 index 000000000000..1b1512db3cfe --- /dev/null +++ b/pkgs/tools/misc/vimpager/default.nix @@ -0,0 +1,6 @@ +{ callPackage }: + +callPackage ./build.nix { + version = "2.06"; + sha256 = "05yr7j72bw64nx7a0y6w9fjmz54zd4g46fn1qjfbbqvbc19fjpl8"; +} diff --git a/pkgs/tools/misc/vimpager/latest.nix b/pkgs/tools/misc/vimpager/latest.nix new file mode 100644 index 000000000000..c98b9a000147 --- /dev/null +++ b/pkgs/tools/misc/vimpager/latest.nix @@ -0,0 +1,7 @@ +{ callPackage }: + +callPackage ./build.nix { + version = "a4da4dfac44d1bbc6986c5c76fea45a60ebdd8e5"; + sha256 = "0gcjpw2q263hh8w2sjvq3f3k2d28qpkkv0jnl8hw1l7v604i8zxg"; +} + diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index dd47e7032aff..0cd9051d2ca7 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -6135,6 +6135,9 @@ in vimer = callPackage ../tools/misc/vimer { }; + vimpager = callPackage ../tools/misc/vimpager { }; + vimpager-latest = callPackage ../tools/misc/vimpager/latest.nix { }; + visidata = (newScope python3Packages) ../applications/misc/visidata { };