Skip to content

Commit

Permalink
mpvScripts.twitch-chat: init at 0-unstable-2024-06-23
Browse files Browse the repository at this point in the history
  • Loading branch information
trueNAHO committed Dec 26, 2024
1 parent 1557114 commit 732505c
Showing 1 changed file with 40 additions and 0 deletions.
40 changes: 40 additions & 0 deletions pkgs/applications/video/mpv/scripts/twitch-chat.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
{
buildLua,
curl,
fetchFromGitHub,
lib,
nix-update-script,
}:
buildLua (finalAttrs: {
pname = "twitch-chat";
version = "0-unstable-2024-06-23";

src = fetchFromGitHub {
owner = "CrendKing";
repo = "mpv-twitch-chat";
rev = "bb0c2e84675f4f1e0c221c8e1d3516b60242b985";
hash = "sha256-WyNPUiAs5U/vrjNbAgyqkfoxh9rabLmuZ1zG5uZYxaw=";
};

installPhase = ''
runHook preInstall
install -D main.lua $out/share/mpv/scripts/twitch-chat.lua
runHook postInstall
'';

passthru.extraWrapperArgs = [
"--prefix"
"PATH"
":"
(lib.makeBinPath [ curl ])
];

passthru.updateScript = nix-update-script { };

meta = {
description = "Show Twitch chat messages as subtitles when watching Twitch VOD with mpv.";
homepage = "https://github.com/CrendKing/mpv-twitch-chat";
license = lib.licenses.mit;
maintainers = [ lib.maintainers.naho ];
};
})

0 comments on commit 732505c

Please sign in to comment.