#!/usr/bin/env python """ hostmask.py - Phenny Hostmask Module """ def get_hostmask(phenny, input): phenny.write(['WHOIS'], input.group(2)) get_hostmask.commands = ['hostmask'] get_hostmask.priority = 'low' # Function to run when 352 Event Occurs def catch_who(phenny, input): # If there is text from the sender if input.group(1): phenny.msg(input.sender, 'Yes') else: phenny.msg(input.sender, 'No') # Notify Command Prompt print 'Caught a WHO event.' # Catch all 352 Events catch_who.rule = r'.*' # Catch 352 Event catch_who.event = '311' # Event Priority catch_who.priority = 'high' # Random Python Hack if __name__ == '__main__': print __doc__.strip()