How to use the karmabot.command.thing.add function in karmabot

To help you get started, we’ve selected a few karmabot examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github chromakode / karmabot / karmabot / extensions / reddit.py View on Github external
@command.thing.add(u"{thing} is a redditor",
                   help=u"link {thing}'s reddit account to their user",
                   exclusive=True)
@command.thing_command
def set_redditor(thing, context):
    thing.attach_persistent(RedditorFacet)
github chromakode / karmabot / karmabot / extensions / twitter.py View on Github external
@command.thing.add(u"{thing} is on twitter",
                   help=u"link {thing}'s twitter account to their user",
                   exclusive=True)
@command.thing_command
def set_twitterer(thing, context):
    thing.attach_persistent(TwitterFacet)