diff options
author | nicoo <nicoo@mur.at> | 2023-11-29 13:24:05 +0000 |
---|---|---|
committer | nicoo <nicoo@mur.at> | 2023-12-04 17:07:46 +0000 |
commit | 492f662817bfd1191b409fb7ee09cf6af847361b (patch) | |
tree | d96f04114c81b340d67788a52ad19785fb49d895 /pkgs/applications/video/mpv | |
parent | ce2dcc6dcb6bdbb6c1be5799ac14aa4874a8739c (diff) | |
download | nixlib-492f662817bfd1191b409fb7ee09cf6af847361b.tar nixlib-492f662817bfd1191b409fb7ee09cf6af847361b.tar.gz nixlib-492f662817bfd1191b409fb7ee09cf6af847361b.tar.bz2 nixlib-492f662817bfd1191b409fb7ee09cf6af847361b.tar.lz nixlib-492f662817bfd1191b409fb7ee09cf6af847361b.tar.xz nixlib-492f662817bfd1191b409fb7ee09cf6af847361b.tar.zst nixlib-492f662817bfd1191b409fb7ee09cf6af847361b.zip |
mpvScripts.uosc: refactor with `buildLua`
Diffstat (limited to 'pkgs/applications/video/mpv')
-rw-r--r-- | pkgs/applications/video/mpv/scripts/default.nix | 2 | ||||
-rw-r--r-- | pkgs/applications/video/mpv/scripts/uosc.nix | 17 |
2 files changed, 6 insertions, 13 deletions
diff --git a/pkgs/applications/video/mpv/scripts/default.nix b/pkgs/applications/video/mpv/scripts/default.nix index fb75464ab98e..4083c52b3d90 100644 --- a/pkgs/applications/video/mpv/scripts/default.nix +++ b/pkgs/applications/video/mpv/scripts/default.nix @@ -22,7 +22,7 @@ in lib.recurseIntoAttrs sponsorblock = callPackage ./sponsorblock.nix { }; thumbfast = callPackage ./thumbfast.nix { inherit buildLua; }; thumbnail = callPackage ./thumbnail.nix { inherit buildLua; }; - uosc = callPackage ./uosc.nix { }; + uosc = callPackage ./uosc.nix { inherit buildLua; }; visualizer = callPackage ./visualizer.nix { }; vr-reversal = callPackage ./vr-reversal.nix { }; webtorrent-mpv-hook = callPackage ./webtorrent-mpv-hook.nix { }; diff --git a/pkgs/applications/video/mpv/scripts/uosc.nix b/pkgs/applications/video/mpv/scripts/uosc.nix index b88cd2c5b968..311b31549ca7 100644 --- a/pkgs/applications/video/mpv/scripts/uosc.nix +++ b/pkgs/applications/video/mpv/scripts/uosc.nix @@ -1,6 +1,6 @@ -{ stdenvNoCC, lib, fetchFromGitHub, makeFontsConf }: +{ buildLua, lib, fetchFromGitHub, makeFontsConf }: -stdenvNoCC.mkDerivation (finalAttrs: { +buildLua (finalAttrs: { pname = "uosc"; version = "4.7.0"; @@ -16,19 +16,12 @@ stdenvNoCC.mkDerivation (finalAttrs: { --replace "mp.find_config_file('scripts')" "\"$out/share/mpv/scripts\"" ''; - dontBuild = true; - - installPhase = '' - runHook preInstall - - mkdir -p $out/share/mpv/ - cp -r scripts $out/share/mpv + scriptPath = "scripts/uosc.lua"; + postInstall = '' + cp -r scripts/uosc_shared $out/share/mpv/ cp -r fonts $out/share - - runHook postInstall ''; - passthru.scriptName = "uosc.lua"; # the script uses custom "texture" fonts as the background for ui elements. # In order for mpv to find them, we need to adjust the fontconfig search path. passthru.extraWrapperArgs = [ |