diff options
author | Benedikt Peetz <benedikt.peetz@b-peetz.de> | 2024-11-24 18:03:44 +0100 |
---|---|---|
committer | Benedikt Peetz <benedikt.peetz@b-peetz.de> | 2024-11-24 18:25:01 +0100 |
commit | e8159ce258ff8e422e985f6161dc9dfde5bbec4c (patch) | |
tree | 511eee51a250f7b96eead98694cf7f7b83adb109 /pkgs/by-name/ct/ctpv/package.nix | |
parent | tests(tests/nvim-checkhealth): Init (diff) | |
download | nixos-config-e8159ce258ff8e422e985f6161dc9dfde5bbec4c.tar.gz nixos-config-e8159ce258ff8e422e985f6161dc9dfde5bbec4c.zip |
fix(pkgs/ctpv): Override to support more than 16 extensions in preview
Diffstat (limited to '')
-rw-r--r-- | pkgs/by-name/ct/ctpv/package.nix | 45 |
1 files changed, 45 insertions, 0 deletions
diff --git a/pkgs/by-name/ct/ctpv/package.nix b/pkgs/by-name/ct/ctpv/package.nix new file mode 100644 index 00000000..48798518 --- /dev/null +++ b/pkgs/by-name/ct/ctpv/package.nix @@ -0,0 +1,45 @@ +{ + lib, + stdenv, + fetchFromGitHub, + makeWrapper, + file, + openssl, +}: +stdenv.mkDerivation rec { + pname = "ctpv"; + version = "1.1"; + + src = fetchFromGitHub { + owner = "NikitaIvanovV"; + repo = pname; + rev = "v${version}"; + hash = "sha256-3BQi4m44hBmPkJBFNCg6d9YKRbDZwLxdzBb/NDWTQP4="; + }; + + nativeBuildInputs = [makeWrapper]; + + buildInputs = [ + file # libmagic + openssl + ]; + + patches = [ + ./allow-up-to-64-types.patch + ]; + + makeFlags = ["PREFIX=$(out)"]; + + preFixup = '' + wrapProgram $out/bin/ctpv \ + --set PATH "${lib.makeBinPath []}"; + ''; + + meta = with lib; { + description = "File previewer for a terminal"; + homepage = "https://github.com/NikitaIvanovV/ctpv"; + license = licenses.mit; + platforms = platforms.linux; + maintainers = [maintainers.wesleyjrz]; + }; +} |