Where do I place my script files?
#1
I'm new to developing for XBMC and I'm trying to write a script that interfaces with peripherals on a Raspberry Pi using Python. I'm testing on my laptop (Debian).

I've generated the Add-on file structure as described here: http://wiki.xbmc.org/index.php?title=Add-on_development

It looks like this:

Code:
script.service.helloworld/
    changelog.txt
    helloworld.py
    helloworld.xml
    icon.png
    LICENSE.txt

helloworld.xml:
Code:
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<addon
   id="script.service.helloworld"
   name="Hello World"
   version="0.0.1"
   provider-name="Thomas Preston">
  <requires>
    <import addon="xbmc.python"                 version="2.1.0"/>
    <import addon="xbmc.addon"                  version="12.0.0"/>
    <import addon="script.common.plugin.cache"  version="1.3.0"/>
  </requires>
  <extension point="xbmc.python.script"         library="helloworld.py">
    <provides>executable</provides>
  </extension>
  <extension point="xbmc.service" library="service.py" start="login"/>
  <extension point="xbmc.addon.metadata">
    <summary lang="en">My first program.</summary>
    <description lang="en">My first program (long desc).</description>
    <disclaimer lang="en">Feel free to use this script however you like.</disclaimer>
    <language>en</language>
    <platform>linux</platform>
    <license>GNU GENERAL PUBLIC LICENSE. Version 3</license>
    <forum></forum>
    <website></website>
    <email></email>
    <source></source>
  </extension>
</addon>

helloworld.py
Code:
print "Hello, World!"

And I've placed it in /home/tom/.xbmc/addons/ but I can't seem to find it anywhere in XBMC and the documentation seems to point me in all sorts of directions (and loops). Also, nothing happens when I restart XBMC.
Reply
#2
helloworld.xml needs to be renamed addon.xml, every thing else looks okay.
Reply
#3
(2013-07-30, 14:59)divingmule Wrote: helloworld.xml needs to be renamed addon.xml, every thing else looks okay.

correct. And you have to restart XBMC then (to have it visible, for further changes in the code you don't need to).
My GitHub. My Add-ons:
Image
Reply

Logout Mark Read Team Forum Stats Members Help
Where do I place my script files?0