mitmproxy/test/scripts/a.py

18 lines
263 B
Python
Raw Normal View History

import argparse
parser = argparse.ArgumentParser()
2013-06-15 22:10:53 +00:00
parser.add_argument('--var', type=int)
var = 0
2013-06-15 22:10:53 +00:00
def start(ctx, argv):
global var
2013-06-15 22:10:53 +00:00
var = parser.parse_args(argv[1:]).var
def here(ctx):
global var
var += 1
return var
def errargs():
pass