Merge pull request #262704 from pks-t/pks-kodi-plugin-video-sendtokodi-0.9.557
kodi.packages.sendtokodi: init at 0.9.557
This commit is contained in:
commit
3ee75d0df5
40
pkgs/applications/video/kodi/addons/sendtokodi/default.nix
Normal file
40
pkgs/applications/video/kodi/addons/sendtokodi/default.nix
Normal file
@ -0,0 +1,40 @@
|
||||
{ lib, buildKodiAddon, fetchFromGitHub, addonUpdateScript, kodi, inputstreamhelper }:
|
||||
|
||||
buildKodiAddon rec {
|
||||
pname = "sendtokodi";
|
||||
namespace = "plugin.video.sendtokodi";
|
||||
version = "0.9.557";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "firsttris";
|
||||
repo = "plugin.video.sendtokodi";
|
||||
rev = "v${version}";
|
||||
hash = "sha256-Ga+9Q7x8+sEmQmteHbSyCahZ/T/l28BAEM84w7bf7z8=";
|
||||
};
|
||||
|
||||
patches = [
|
||||
./use-packaged-deps.patch
|
||||
];
|
||||
|
||||
propagatedBuildInputs = [
|
||||
inputstreamhelper
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
# Remove vendored youtube-dl and yt-dlp libraries.
|
||||
rm -r lib/
|
||||
'';
|
||||
|
||||
passthru = {
|
||||
# Instead of the vendored libraries, we propagate youtube-dl and yt-dlp via
|
||||
# the Python path.
|
||||
pythonPath = with kodi.pythonPackages; makePythonPath [ youtube-dl yt-dlp ];
|
||||
};
|
||||
|
||||
meta = with lib; {
|
||||
homepage = "https://github.com/firsttris/plugin.video.sendtokodi";
|
||||
description = "Plays various stream sites on Kodi using youtube-dl";
|
||||
license = licenses.mit;
|
||||
maintainers = teams.kodi.members ++ [ maintainers.pks ];
|
||||
};
|
||||
}
|
@ -0,0 +1,16 @@
|
||||
diff --git a/service.py b/service.py
|
||||
index 1d7b6e4..9782993 100644
|
||||
--- a/service.py
|
||||
+++ b/service.py
|
||||
@@ -241,9 +241,9 @@ def playlistIndex(url, playlist):
|
||||
|
||||
# Use the chosen resolver while forcing to use youtube_dl on legacy python 2 systems (dlp is python 3.6+)
|
||||
if xbmcplugin.getSetting(int(sys.argv[1]),"resolver") == "0" or sys.version_info[0] == 2:
|
||||
- from lib.youtube_dl import YoutubeDL
|
||||
+ from youtube_dl import YoutubeDL
|
||||
else:
|
||||
- from lib.yt_dlp import YoutubeDL
|
||||
+ from yt_dlp import YoutubeDL
|
||||
|
||||
# patch broken strptime (see above)
|
||||
patch_strptime()
|
@ -164,6 +164,8 @@ let self = rec {
|
||||
|
||||
routing = callPackage ../applications/video/kodi/addons/routing { };
|
||||
|
||||
sendtokodi = callPackage ../applications/video/kodi/addons/sendtokodi { };
|
||||
|
||||
signals = callPackage ../applications/video/kodi/addons/signals { };
|
||||
|
||||
simplejson = callPackage ../applications/video/kodi/addons/simplejson { };
|
||||
|
Loading…
Reference in New Issue
Block a user