Example #1
0
def getHelp(args, author):
    if len(args) < 3:
        banner = fetchFile('help', 'schedule')
        if is_admin(author.roles):
            banner += '`!schedule override USER.ID USER.NAME LOCATION` to change a user\'s set location.\n'
        return banner
    else:  #Get list of cities or continents
        return fetchFile('locales', args[2].lower())
Example #2
0
async def getTodaysWord():
    print('[+] Updating word of the day')
    async with aiohttp.ClientSession() as session:
        async with session.get(url) as resp:
            if resp.status == 200:
                text = await resp.read()
            else:
                print("[!] Status " + str(resp.status))
    soup = BeautifulSoup(text, "html.parser")
    text = soup.get_text()
    text = text.split('with Anu Garg')
    text = text[1].split('A THOUGHT FOR TODAY')
    text = text[0].strip()
    writeFile(text)
    stripBlank()
    return fetchFile('.', 'output')
Example #3
0
def getHelp():
    return fetchFile('help', 'filters')
Example #4
0
def importExts():
    listOfFiles = {'audio', 'docs', 'images', 'video'}
    for file_ in listOfFiles:
        f = fetchFile('ext', file_).strip('\n')
        extSet[file_] = f.split()
Example #5
0
def getHelp(author):
    banner = fetchFile('help', 'riddles')
    if is_admin(author.roles):
        banner += "`!riddle delete RIDDLE.ID` remove a riddle.\n"
        banner += "`!riddle reset` DANGEROUS! delete all users and all riddles.\n"
    return banner
Example #6
0
def getHelp(author):
    banner = fetchFile('help', 'quotes')
    if is_admin(author.roles):
        banner += "React to a message with ❌ to remove it."
    return banner
Example #7
0
def getHelp():
	return [None, fetchFile('help', 'stats')]