I’ve previously had a netflix-prep, since Google closed the old libwidevine and all the Issues Netflix have plagued the addon with, I thought I’d make it less Netflix oriented since there are a multitude of addons, depending on libwidevine, for example Netflix, Disney+, Viaplay, DANZ.
So I wrote this script instead, it grabs the python dependencies and installs them, stop mediacenter service, patches the kodi execution call.
Just looking at your script.
2 things come to my mind:
I am wondering - if there is a default configuration directory for kodi/media-center?
as systemd is used, it is common to have a configuration-override file in /etc/default read by the syetemd-script when starting media-center.
@sam_nazarko - any chance the mediacenter script could get an “OPTIONS” variable it handles?
And that one would be loaded through /etc/default/mediacenter as options?
That would make some integrations easier in the long run.
Did you think about using error-levels in your script to make it exit if an error occurs?
I do it like this:
mkdir ~/temp_glibc
errlvl=$?
if [ $errlvl -gt 0 ]
then
"*** FATAL: Unable to create temporary download directory. Exiting!"
exit 1
fi
At least, the script would not continue and eventually break some things.
There will be plenty of people who want to use this script who don’t know Linux and aren’t familiar with GitHub. I think you can probably assume the user knows how to reach an SSH prompt; but from that point on you should include step by step instructions on downloading and running the script.
@Smurphy I’m all for people PR improvements, I just put this together like in10 mins, copy and pasting from my Netflix script and some early instructions from Sam. I should edit it since the “sed” might not be needed anymore.
@angry.sardine Well, I did this at like 1 am, wasn’t in the mood for writing a “how to”, but you are welcome to do it =), I might be able to take a shot at it later this weekend. I usually do nice dialogs and such, but this script is just raw command execution.
ps. heck, while I was here i made a small instruction
I have a question: which version of the widevine libraries it’s be downloaded and installed at today ?
I made this question because, if i remember, i have installed the 4.10.2252.0 but yesterday afternoon, while i was using kodi and i was using youtube addons (strange), i have obtain a pop up on tv and it told me that an update of this library was available.
I could answer yes or no (lol).
I answered no because in the past by answering yes I had made DAZN no longer usable… in fact last night I was able to watch Inter vs Juventus on DAZN whitout any issue from my Rpi2 and current osmc build.