Skip to main content

A very strange method of declaring commands with hikari-lightbulb

Project description

Lightbulb WTF

This is a joke project (but working somehow).

I just wanted to mess around to see how much I could mess with lightbulb command declaration syntax.

Usage

Commands are declared like generics using square brackets ([]) as the construction method.

A basic command:

import lightbulb
from lightbulb.ext.wtf import *

bot = lightbulb.BotApp(...)

async def foo_callback(ctx):
    await ctx.respond("Bar")


cmd = Command[
    Implements[lightbulb.PrefixCommand],
    Name["foo"],
    Description["test command"],
    Executes[foo_callback]
]

bot.command(cmd)
bot.run()

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

lightbulb-ext-wtf-0.1.0.tar.gz (7.4 kB view hashes)

Uploaded Source

Built Distribution

lightbulb_ext_wtf-0.1.0-py3-none-any.whl (8.4 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page