depot/third_party/nixpkgs/pkgs/by-name/in/invidtui/package.nix
Default email f34ce41345 Project import generated by Copybara.
GitOrigin-RevId: b73c2221a46c13557b1b3be9c2070cc42cf01eb3
2024-07-27 08:49:29 +02:00

32 lines
905 B
Nix

{ lib, buildGoModule, fetchFromGitHub, yt-dlp, ffmpeg, mpv }:
buildGoModule rec {
pname = "invidtui";
version = "0.4.6";
src = fetchFromGitHub {
owner = "darkhz";
repo = "invidtui";
rev = "refs/tags/v${version}";
hash = "sha256-C465lzbZIh8LYDUHNa5u66nFteFsKAffilvy1Danfpg=";
};
vendorHash = "sha256-C7O2GJuEdO8geRPfHx1Sq6ZveDE/u65JBx/Egh3cnK4=";
doCheck = true;
postPatch = ''
substituteInPlace cmd/flags.go \
--replace "\"ffmpeg\"" "\"${lib.getBin ffmpeg}/bin/ffmpeg\"" \
--replace "\"mpv\"" "\"${lib.getBin mpv}/bin/mpv\"" \
--replace "\"yt-dlp\"" "\"${lib.getBin yt-dlp}/bin/yt-dlp\""
'';
meta = with lib; {
homepage = "https://darkhz.github.io/invidtui/";
description = "Invidious TUI client";
license = licenses.mit;
maintainers = with maintainers; [ rettetdemdativ ];
mainProgram = "invidtui";
};
}