return 20
class PipeIdler(StringIdler):
- def __init__(self, v, command):
+ def __init__(self, v, command, args):
text = "I ate my cookie...."
if os.access(command,os.F_OK|os.X_OK):
- (stdout, stdin) = popen2.popen2(command)
+ (stdout, stdin) = popen2.popen2(command+' '+args)
text = string.join(stdout.readlines())
stdout.close()
stdin.close()
def display(self, string):
if len(string) > 10:
string = string[0:10]
+ string = re.sub('(.)\.', lambda match: '.'+match.group(1), string)
self.wfh.write('D'+string+'\n')
(code, string) = self.get_response()
return (code == '300', code, string)