aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorroot <root@pigstarter.de>2014-06-13 13:18:21 +0200
committerroot <root@pigstarter.de>2014-06-13 13:18:21 +0200
commit0fe9b8fbad6801d244d1df70bbf7bdb1d2c599f9 (patch)
tree6323394dc147569f56164f528f0248a3be02314a
parent17f3fc71f06f4b27ee3831114dcca7b80384e334 (diff)
update bgt titlebot
-rwxr-xr-xtitlebot/commands/undo2
-rwxr-xr-xtitlebot/commands/up2
-rw-r--r--titlebot/titlebot.py5
3 files changed, 5 insertions, 4 deletions
diff --git a/titlebot/commands/undo b/titlebot/commands/undo
index a66de67..e1b0aba 100755
--- a/titlebot/commands/undo
+++ b/titlebot/commands/undo
@@ -15,7 +15,7 @@ except:
print("""usage: undo number (...)
undos vote of one or more entries based on .list""")
sys.exit(1)
-voter = environ['_prefix']
+voter = environ['_prefix'].split("@")[1]
voter_name = environ['_from']
for vote in votes:
try:
diff --git a/titlebot/commands/up b/titlebot/commands/up
index 0a48bdb..7aff594 100755
--- a/titlebot/commands/up
+++ b/titlebot/commands/up
@@ -15,7 +15,7 @@ if not votes:
upvotes one or more entries based on .list""")
sys.exit(1)
-voter = environ['_prefix']
+voter = environ['_prefix'].split("@")[1]
voter_name =environ['_from']
for vote in votes:
try:
diff --git a/titlebot/titlebot.py b/titlebot/titlebot.py
index c1eac3b..4171748 100644
--- a/titlebot/titlebot.py
+++ b/titlebot/titlebot.py
@@ -6,7 +6,7 @@ debug = False
# CAVEAT name should not contains regex magic
name = 'bgt_titlebot'
-workdir = '/tmp/state'
+workdir = '/home/titlebot/state'
try:
mkdir(workdir)
@@ -68,7 +68,8 @@ public_commands = [
# identify via direct connect
{ 'capname': 'identify',
'pattern': '^identify' + '\\s*(?:\\s+(?P<args>.*))?$',
- 'argv' : [ 'commands/identify' ]}
+ 'argv' : [ 'commands/identify' ],
+ 'env':{'config_filename': config_filename}}
]
commands = [
default_command('reload'),