mirror of
https://github.com/Kunsi/scheduled-plugin-pretalx-broadcast-tools.git
synced 2024-11-22 01:51:03 +00:00
support all kinds of node names
This commit is contained in:
parent
80777081c3
commit
aba29ffa52
2 changed files with 4 additions and 6 deletions
|
@ -7,10 +7,6 @@ pretalx installation!
|
|||
|
||||
[Import this package to info-beamer.com](https://info-beamer.com/use?url=https%3A%2F%2Fgithub.com%2FKunsi%2Fscheduled-plugin-pretalx-broadcast-tools.git)
|
||||
|
||||
It's important that you import this plugin under one of the paths
|
||||
`pretalx` or `pretalx-broadcast-tools` into your setup. Otherwise
|
||||
no information will be shown!
|
||||
|
||||
## Features
|
||||
|
||||
* show the next talk in the configured room
|
||||
|
|
6
service
6
service
|
@ -1,4 +1,5 @@
|
|||
#!/usr/bin/python
|
||||
import os
|
||||
import sys
|
||||
import time
|
||||
import traceback
|
||||
|
@ -11,6 +12,8 @@ from hosted import config, node
|
|||
|
||||
config.restart_on_update()
|
||||
|
||||
SEND_PREFIX = os.environ["NODE"].replace("root/", "root/plugin/")
|
||||
|
||||
|
||||
def log(msg):
|
||||
sys.stderr.write("[pretalx] {}\n".format(msg))
|
||||
|
@ -39,8 +42,7 @@ def idle(seconds, event_start, event_tz):
|
|||
send_data["day"] = day_info.days
|
||||
|
||||
for k, v in send_data.items():
|
||||
node.send_raw("root/plugin/pretalx/{}:{}".format(k, v))
|
||||
node.send_raw("root/plugin/pretalx-broadcast-tools/{}:{}".format(k, v))
|
||||
node.send_raw("{}/{}:{}".format(SEND_PREFIX, k, v))
|
||||
time.sleep(1)
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue