diff options
author | Azat Bahawi <azat@bahawi.net> | 2023-09-30 15:21:49 +0300 |
---|---|---|
committer | Azat Bahawi <azat@bahawi.net> | 2023-09-30 15:21:49 +0300 |
commit | 0221d5913ea26fde9493dadfbb265f2ff103124f (patch) | |
tree | 29258145f96ffd9bcf5e39f6a1e1e7c4cab57355 /packages/mpv-autosub.nix | |
parent | 2023-09-28 (diff) |
2023-09-30
Diffstat (limited to '')
-rw-r--r-- | packages/mpv-autosub.nix | 20 |
1 files changed, 17 insertions, 3 deletions
diff --git a/packages/mpv-autosub.nix b/packages/mpv-autosub.nix index 3d8171d..e3fc221 100644 --- a/packages/mpv-autosub.nix +++ b/packages/mpv-autosub.nix @@ -1,15 +1,17 @@ { fetchFromGitHub, + lib, + mpv-unwrapped, python3Packages, stdenvNoCC, }: -stdenvNoCC.mkDerivation rec { +stdenvNoCC.mkDerivation (finalAttrs: { pname = "mpv-autosub"; version = "unstable-2021-06-29"; src = fetchFromGitHub { owner = "davidde"; - repo = pname; + repo = finalAttrs.pname; rev = "35115355bd339681f97d067538356c29e5b14afa"; hash = "sha256-BKT/Tzwl5ZA4fbdc/cxz0+CYc1zyY/KOXc58x5GYow0="; }; @@ -25,8 +27,20 @@ stdenvNoCC.mkDerivation rec { ''; installPhase = '' + runHook preInstall + install -Dm644 autosub.lua $out/share/mpv/scripts/autosub.lua + + runHook postInstall ''; passthru.scriptName = "autosub.lua"; -} + + meta = with lib; { + description = "Automatic downloading of subtitles for MPV"; + inherit (finalAttrs.src.meta) homepage; + license = licenses.mit; + inherit (mpv-unwrapped.meta) platforms; + maintainers = with maintainers; [azahi]; + }; +}) |