mirror of
http://aero2k.de/t/repos/urlbot-native.git
synced 2017-09-06 15:25:38 +02:00
scope fixes; moved VERSION to conf()
This commit is contained in:
@@ -18,6 +18,8 @@ config['hist_max_time'] = 10 * 60
|
||||
config['uptime'] = -time.time()
|
||||
config['request_counter'] = 0
|
||||
|
||||
config['version'] = None
|
||||
|
||||
|
||||
# the "dice" feature will use more efficient random data (0) for given users
|
||||
config['enhanced-random-user'] = ( 'FIXME', 'FIXME' )
|
||||
|
||||
@@ -110,7 +110,7 @@ def command_version(args):
|
||||
|
||||
if 'version' in args['data']:
|
||||
return {
|
||||
'msg': args['reply_user'] + (''': I'm running ''' + VERSION)
|
||||
'msg': args['reply_user'] + (''': I'm running ''' + conf('version'))
|
||||
}
|
||||
|
||||
def command_unicode(args):
|
||||
|
||||
@@ -244,8 +244,8 @@ plugins.time = time
|
||||
plugins.register_all()
|
||||
|
||||
if '__main__' == __name__:
|
||||
VERSION = get_version_git()
|
||||
print sys.argv[0] + ' ' + VERSION
|
||||
set_conf('version', get_version_git())
|
||||
print sys.argv[0] + ' ' + conf('version')
|
||||
|
||||
if not os.path.exists(fifo_path):
|
||||
logger('error', 'fifo_path "%s" does not exist, exiting' % fifo_path)
|
||||
|
||||
Reference in New Issue
Block a user