2016-05-16, 11:39
A very simple question...
I am following wiki's video addon, it can be possible to run a script instead of playing a video changing "url" variable?
I just want to make a simple list with 2 or 3 actions for running bash or python scripts and I wonder if I can use something like:
I can not make it work... any help?
thanks!
I am following wiki's video addon, it can be possible to run a script instead of playing a video changing "url" variable?
Code:
import sys
import xbmcgui
import xbmcplugin
addon_handle = int(sys.argv[1])
xbmcplugin.setContent(addon_handle, 'movies')
url = 'http://localhost/some_video.mkv'
li = xbmcgui.ListItem('My First Video!', iconImage='DefaultVideo.png')
xbmcplugin.addDirectoryItem(handle=addon_handle, url=url, listitem=li)
xbmcplugin.endOfDirectory(addon_handle)
I just want to make a simple list with 2 or 3 actions for running bash or python scripts and I wonder if I can use something like:
Code:
url='System.Exec(/storage/path_to_my_script.sh)'
I can not make it work... any help?
thanks!