# HG changeset patch # User devlinjs@FA7CZA6N1254998.wrightpatterson.afmc.ds.af.mil # Date 1198270593 18000 # Node ID 061f40299ed5b37a3472c871bed3b2c84584014d # Parent ebefe2d57e3bedf12f3e2f23eef366c7651d252c ed now perfect except for eof diff -r ebefe2d57e3b -r 061f40299ed5 cmd2.py --- a/cmd2.py Fri Dec 21 15:31:17 2007 -0500 +++ b/cmd2.py Fri Dec 21 15:56:33 2007 -0500 @@ -139,14 +139,14 @@ except ImportError: pass - def do_EOF(self, arg): return True do_eof = do_EOF - statementEndPattern = re.compile(r'([%s]\s*)|(EOF)$' % terminators) + statementEndPattern = re.compile(r'[%s]\s*$' % terminators) def statementHasEnded(self, lines): - return bool(self.statementEndPattern.search(lines)) + return bool(self.statementEndPattern.search(lines)) \ + or lines[-3:] == 'EOF' def clean(self, s): """cleans up a string"""