Share your scripts or request scripts with specific features.
Forum rules
Please keep the forum clean - one topic per script. Questions not related to a specific script should be posted in Support forum.
-
svenglar
- Posts: 4
- Joined: 03 Aug 2015, 20:43
Post
by svenglar » 07 Nov 2015, 23:10
This is a very simple script that will hit Kodi's HTTP API to trigger a refresh of the video library:
https://github.com/natemccurdy/nzbget-update_kodi
In order to use this, the "Allow remote control via HTTP" setting under "web server" must be enabled.
It works best when triggered after video files have been sorted (for example, after VideoSort).
This has been tested, and is working with:
NZBGet => 16.2 and 16.3
Kodi => 15.2
-
hugbug
- Developer & Admin
- Posts: 7645
- Joined: 09 Sep 2008, 11:58
- Location: Germany
Post
by hugbug » 07 Nov 2015, 23:16
Thanks for sharing the script.
-
jackiass2
- Posts: 42
- Joined: 19 Nov 2013, 12:07
Post
by jackiass2 » 22 Nov 2015, 06:11
I'm getting:
Code: Select all
Kodi is not running; skipping update
Kodi 15.1
Nzbget 16.3
OS: OpenElec 5.95.2
Hardware: RPi2.arm
IP: 192.168.87.107
Port: 80
IP and Port are the same ones that work with the Kore app and other remote controllers.
Is it btw OK to use localhost as IP?
-
svenglar
- Posts: 4
- Joined: 03 Aug 2015, 20:43
Post
by svenglar » 22 Nov 2015, 20:01
The reason you're seeing that message is because of this check to see if Kodi is running:
Code: Select all
kodi_running="$(/usr/bin/pgrep kodi.bin)"
if [[ -z $kodi_running ]]; then
echo "[DETAIL] Kodi is not running; skipping update"
exit $SKIP
fi
If Kodi is not running, then I skip the check. There's two reasons for this. The first is because the script will exit with and error code if curl can't reach its target. The second is because there's no point in trying to hit the API if it's not available locally.
I wrote this script to work in my environment where Kodi and NZBGet are running on the same Ubuntu 14.04 host. This has a major flaw in that, 1) it won't work if Kodi is on a different host than NZBGet, and 2) it won't work if
doesn't find a running instance of Kodi.
Anyway, I just pushed a new release of the script with better error handling and true support for remote hosts. Please try the new version and let me know if you get any more error messages:
https://github.com/natemccurdy/nzbget-u ... ree/v1.1.0
-
Whiteney07
- Posts: 1
- Joined: 29 Sep 2018, 06:28
Post
by Whiteney07 » 29 Sep 2018, 06:54
This
guide is to help you move your media to a new location without losing all of your current watched statuses, date added, last played, resume time (for shows/movies that you started watching and did not finish), etc.
Who is online
Users browsing this forum: No registered users and 36 guests