Add log level config option
* Log levels can now be set via the command line and the configuration file. * ServerConfig.load() function takes a file-like object now, rather than a string Signed-off-by: Alek Ratzloff <alekratz@gmail.com>
This commit is contained in:
@@ -23,7 +23,8 @@ async def main():
|
||||
channel = sys.argv[1]
|
||||
files = sys.argv[2:]
|
||||
server_config = ServerConfig()
|
||||
server_config.load("config.toml")
|
||||
with open("config.toml") as fp:
|
||||
server_config.load(fp)
|
||||
# This only works on one plugin per config
|
||||
bot = Bot(server_config)
|
||||
plugin = [plugin for plugin in bot.plugins if isinstance(plugin, Markov)][0]
|
||||
|
||||
Reference in New Issue
Block a user