diff options
author | Doron Behar <doron.behar@gmail.com> | 2020-06-07 09:02:13 +0300 |
---|---|---|
committer | Profpatsch <mail@profpatsch.de> | 2020-06-11 17:18:23 +0200 |
commit | d60b5aaa2fbc68fa1609c30ee2f805f575c4a3f5 (patch) | |
tree | 9e1e211e58da9d60c74220d10cefe4ef2d1e005b /pkgs/applications | |
parent | ee540d4ff709e63cfcdd7a6dfb0cce803a848624 (diff) |
wrapMpv: Use lib.strings.escapeShellArgs
Instead of manually quoting the strings, use the library function to do it more reliably.
Diffstat (limited to 'pkgs/applications')
-rw-r--r-- | pkgs/applications/video/mpv/wrapper.nix | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/pkgs/applications/video/mpv/wrapper.nix b/pkgs/applications/video/mpv/wrapper.nix index 1658f922ab3b6..ad6383046b1bc 100644 --- a/pkgs/applications/video/mpv/wrapper.nix +++ b/pkgs/applications/video/mpv/wrapper.nix @@ -32,10 +32,10 @@ let # All arguments besides the input and output binaries (${mpv}/bin/mpv and # $out/bin/mpv). These are used by the darwin specific makeWrapper call # used to wrap $out/Applications/mpv.app/Contents/MacOS/mpv as well. - mostMakeWrapperArgs = builtins.concatStringsSep " " ([ "--argv0" "'$0'" + mostMakeWrapperArgs = lib.strings.escapeShellArgs ([ "--argv0" "'$0'" # These are always needed (TODO: Explain why) - "--prefix" "LUA_CPATH" "\\;" "${mpv.luaEnv}/lib/lua/${mpv.lua.luaversion}/\\?.so" - "--prefix" "LUA_PATH" "\\;" "${mpv.luaEnv}/share/lua/${mpv.lua.luaversion}/\\?.lua" + "--prefix" "LUA_CPATH" ";" "${mpv.luaEnv}/lib/lua/${mpv.lua.luaversion}/?.so" + "--prefix" "LUA_PATH" ";" "${mpv.luaEnv}/share/lua/${mpv.lua.luaversion}/?.lua" ] ++ lib.optionals mpv.vapoursynthSupport [ "--prefix" "PYTHONPATH" ":" "${mpv.vapoursynth}/lib/${mpv.vapoursynth.python3.sitePackages}" ] ++ lib.optionals (binPath != "") [ @@ -52,7 +52,7 @@ let ) scripts )) ++ extraMakeWrapperArgs) ; - umpvWrapperArgs = builtins.concatStringsSep " " ([ + umpvWrapperArgs = lib.strings.escapeShellArgs ([ "--argv0" "'$0'" "--set" "MPV" "$out/bin/mpv" ] ++ extraUmpvWrapperArgs) |