Indentation change 3-4 spaces.
Possible files that need to be cleanedup; commands/info.py:cmd_list commands/general.py:cmd_who commands/comsys.py:cmd_who cmdtable.py ansi.py
This commit is contained in:
parent
740d715c72
commit
3fe644ef17
31 changed files with 1856 additions and 1856 deletions
38
gameconf.py
38
gameconf.py
|
|
@ -8,26 +8,26 @@ Handle the setting/retrieving of server config directives.
|
|||
"""
|
||||
|
||||
def host_os_is(osname):
|
||||
"""
|
||||
Check to see if the host OS matches the query.
|
||||
"""
|
||||
if os.name == osname:
|
||||
return True
|
||||
return False
|
||||
"""
|
||||
Check to see if the host OS matches the query.
|
||||
"""
|
||||
if os.name == osname:
|
||||
return True
|
||||
return False
|
||||
|
||||
def get_configvalue(configname):
|
||||
"""
|
||||
Retrieve a configuration value.
|
||||
"""
|
||||
try:
|
||||
return ConfigValue.objects.get(conf_key__iexact=configname).conf_value
|
||||
except:
|
||||
functions_general.log_errmsg("Unable to get config value for %s:\n%s" % (configname, (format_exc())))
|
||||
"""
|
||||
Retrieve a configuration value.
|
||||
"""
|
||||
try:
|
||||
return ConfigValue.objects.get(conf_key__iexact=configname).conf_value
|
||||
except:
|
||||
functions_general.log_errmsg("Unable to get config value for %s:\n%s" % (configname, (format_exc())))
|
||||
|
||||
def set_configvalue(configname, newvalue):
|
||||
"""
|
||||
Sets a configuration value with the specified name.
|
||||
"""
|
||||
conf = ConfigValue.objects.get(conf_key=configname)
|
||||
conf.conf_value = newvalue
|
||||
conf.save()
|
||||
"""
|
||||
Sets a configuration value with the specified name.
|
||||
"""
|
||||
conf = ConfigValue.objects.get(conf_key=configname)
|
||||
conf.conf_value = newvalue
|
||||
conf.save()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue