예제 #1
0
 def do_generate_int_macro(self, line):
     if line == '':
         raise PappyException('Macro name is required')
     args = shlex.split(line)
     name = args[0]
     script_str = gen_imacro()
     fname = 'int_%s.py' % name
     with open(fname, 'wc') as f:
         f.write(script_str)
     print 'Wrote script to %s' % fname
예제 #2
0
 def do_generate_int_macro(self, line):
     if line == '':
         raise PappyException('Macro name is required')
     args = shlex.split(line)
     name = args[0]
     script_str = gen_imacro()
     fname = 'int_%s.py' % name
     with open(fname, 'wc') as f:
         f.write(script_str)
     print 'Wrote script to %s' % fname
예제 #3
0
def generate_int_macro(line):
    """
    Generate an intercepting macro script
    Usage: generate_int_macro <name>
    """
    if line == '':
        raise PappyException('Macro name is required')
    args = shlex.split(line)
    name = args[0]
    script_str = gen_imacro()
    fname = 'int_%s.py' % name
    with open(fname, 'wc') as f:
        f.write(script_str)
    print 'Wrote script to %s' % fname
예제 #4
0
def generate_int_macro(line):
    """
    Generate an intercepting macro script
    Usage: generate_int_macro <name>
    """
    if line == "":
        raise PappyException("Macro name is required")
    args = shlex.split(line)
    name = args[0]
    script_str = gen_imacro()
    fname = "int_%s.py" % name
    with open(fname, "wc") as f:
        f.write(script_str)
    print "Wrote script to %s" % fname