I just want to execute a script from OSGI command console (which you get with ./start.sh), but im getting errors:
osgi> openhab
—openHAB commands—
openhab send - sends a command for an item
openhab update - sends a status update for an item
openhab status - shows the current status of an item
openhab items [] - lists names and types of all items matching the pattern
openhab say - Says a message through TTS on the host machine
openhab > - Executes a script
osgi> openhab > demo
___ demo Couldn’t resolve reference to JvmIdentifiableElement ‘demo’.; line 1, column 0, length 4
I also tried setting up xmmp, but that seems overkill for just wanting to execute a script.
Xmmmp connects, but it doesnt receive the messages from the other user. The tutorial says it should work: https://github.com/openhab/openhab/wiki/Scripts (Section: Calling Scripts) But it seems the openhab xmpp user doesnt receive hte messages. But i can see its online status.
(Note formatting went wrong in the initial question)
I mean that the openhab > <script> command in the osgi console, which is the input/ouput via the console after you run ./start.sh, doesnt work.
You could try reproducing it yourselve:
./start.sh
help openhab
openhab > scriptname
Note, its openhab 1.8, not 2.0
Example output:
help openhab
---openHAB commands---
openhab send <item> <command> - sends a command for an item
openhab update <item> <state> - sends a status update for an item
openhab status <item> - shows the current status of an item
openhab items [<pattern>] - lists names and types of all items matching the pattern
openhab say <sentence to say> - Says a message through TTS on the host machine
openhab > <script to execute> - Executes a script
osgi> openhab > demo
___ demo
Couldn't resolve reference to JvmIdentifiableElement 'demo'.; line 1, column 0, length 4
osgi>