from pathlib import Path from deltachat2 import NewMsgEvent from quadnite_bot.command import Command, Context class HelpCommand(Command): command = "help" def __init__(self): self.responses = [] for file in sorted((Path(__file__).resolve().parent.parent / "static/help").iterdir()): with open(file) as f: self.responses.append(f.read()) def process_event(self, ctx: Context, event: NewMsgEvent) -> None: for response in self.responses: ctx.reply(response)