2012-09-18, 08:42
hello,
i've been googling for ages...im going around in circles.
please help.
i want to run a shell script or python which ever from a menu item somewhere.
i've tried advanced launcher...it didn't work.
please help.
(2012-09-18, 08:42)xbmcn00b Wrote: hello,To start a shell script command line is generally :
i've been googling for ages...im going around in circles.
please help.
i want to run a shell script or python which ever from a menu item somewhere.
i've tried advanced launcher...it didn't work.
/bin/sh /path/to/the/script.sh
/usr/bin/python /path/to/the/script.py
(2012-09-18, 19:24)Angelscry Wrote: So into advanced launcher you need to create a stand alone launcher and select /bin/sh or /usr/bin/python as application and indicate /path/to/the/script.sh or /path/to/the/script.py as arguments.
If you plan to start several sh scripts or (python scripts) the best move is to put all your script into the same directory and create a file launcher and configure it like this :
[b]application: /bin/sh (or /usr/bin/python)item path: /path/to/the/scripts/
arguments: "%rom%"
file extension: sh (or py)[/b]
(2012-12-11, 20:48)MacOCD Wrote: I'm Hijacking a few months old thread here, but my problem is the same so it seems daft to start another...I think your problem come to the fact that you are using an old and deprecated version of Advanced Launcher. Version 1.7.6 is 10 months old and not compatible with last XBMC Frodo releases. Nearly 30 different versions of Advanced Launcher have been released since. The latest version of Advanced Launcher is 1.10.7. I strongly suggest you to install my repository to have Advanced Launcher updated regularly.
When trying to find a solution to running shell or python scripts from the XMBC interface the following solution was given.
(2012-09-18, 19:24)Angelscry Wrote: So into advanced launcher you need to create a stand alone launcher and select /bin/sh or /usr/bin/python as application and indicate /path/to/the/script.sh or /path/to/the/script.py as arguments.
If you plan to start several sh scripts or (python scripts) the best move is to put all your script into the same directory and create a file launcher and configure it like this :
[b]application: /bin/sh (or /usr/bin/python)item path: /path/to/the/scripts/
arguments: "%rom%"
file extension: sh (or py)[/b]
This would be perfect for what I want to do with a lot of VPN scripts, the instructions are really clear to me, but it just doesn't work for me in Frodo. All my scripts run perfectly when I SSH in, whether I use '/bin/sh /home/pi/myvpn.sh ' or if I chmod 755 them and run './myvpn'.
Through the XBMC menu I previously had the same "Script Failed! : add-on.py" others in my searches were having. Using this alternative technique (highlighted in blue) I get "Working.." Then nothing, no list of scripts to run.
I'm using XBMC 12.0Beta3 Git:20121209-7f49891
Advanced Launcher 1.7.6 downloaded from the XBMC 12Beta version's built in Addons repository. (Update Option appears Greyed out)
Is this a Frodo thing? If so Is there a solution or an alternative method to getting these VPNs from the XBMC interface?
Is 1.7.6 the latest version of Advanced Launcher under Frodo? If not what repository do I need to install to get a newer version?
I've only has a Raspberry Pi for a couple of days and already have BBC iPlayer, DVBLogic LiveTV sussed and VPNs sorted (sort of), I just can't work out how to launch the VPN scripts from the XMBC interface.
Any help appreciated,
Thanks
(2012-12-11, 21:00)Angelscry Wrote: I think your problem come to the fact that you are using an old and deprecated version of Advanced Launcher. Version 1.7.6 is 10 months old and not compatible with last XBMC Frodo releases. Nearly 30 different versions of Advanced Launcher have been released since.
Quote:The latest version of Advanced Launcher is 1.10.7. I strongly suggest you to install my repository to have Advanced Launcher updated regularly.
(2012-12-11, 22:14)MacOCD Wrote:I have just created and tested an .sh script launcher and it works perfectly. I have create several .sh scripts (make them excutable) and put all of them into the same directory. Then I have created a file launcher like this :(2012-12-11, 21:00)Angelscry Wrote: I think your problem come to the fact that you are using an old and deprecated version of Advanced Launcher. Version 1.7.6 is 10 months old and not compatible with last XBMC Frodo releases. Nearly 30 different versions of Advanced Launcher have been released since.
I had a suspicion that I may be using an out of date version, I installed Advanced Launcher directly from within Frodo and the option to update was greyed out. I thought the version that XBMC12 has in it's repository would be compatible with XBMC12, not an unreasonable assumption. I took the 'Eden Only' warning to mean prior XBMC iterations before Eden were not compatible.
Quote:The latest version of Advanced Launcher is 1.10.7. I strongly suggest you to install my repository to have Advanced Launcher updated regularly.
Now I know your repository location I've installed it and I'm using 1.10.7, thanks
My individual scripts are now working, although the technique you suggested previously for selecting from multiple scripts doesn't seem to list any scripts to choose. My scripts are located in the /home/pi/ folder, I renamed them with a .sh extension and added sh AND .sh to the Modify Items extensions setting.
But I'm happy that I can select my individual VPNs now, I'll just make a different launcher for each of them and add them all to favourites.
Thanks.
(2012-12-12, 05:11)Angelscry Wrote: I have just created and tested an .sh script launcher and it works perfectly. I have create several .sh scripts (make them excutable) and put all of them into the same directory. Then I have created a file launcher like this :
Application : /bin/sh
Argument : "%rom%"
File path : directory where are located the created .sh scripts.
File extension : sh
Then into Advanced Launcher settings put "Collecting Method" to none for Data, Thumbs and Fanarts Scan Settings. Finally select "Add Items" menu entry and choose "Scan for new items" option. All your .sh script must have been added. Select one of them to start your scripts.