def exec_blob(blob): pb = Plumbum() for st in parse_blob(blob): pb.define(st) pb.run()
def exec_file(fname): fh = sys.stdin if fname == '-' else open(fname) pb = Plumbum() for st in parse_file(fh): pb.define(st) pb.run()