# HG changeset patch # User catherine@Elli.myhome.westell.com # Date 1236906127 14400 # Node ID ae1d89f09a88d1441b746ef269b5bc609d3cfb73 # Parent aa33f495a2898edb4fae71cfa6402fec47ed4777 new \di diff -r aa33f495a289 -r ae1d89f09a88 sqlpython/mysqlpy.py --- a/sqlpython/mysqlpy.py Thu Mar 12 17:36:25 2009 -0400 +++ b/sqlpython/mysqlpy.py Thu Mar 12 21:02:07 2009 -0400 @@ -106,17 +106,14 @@ which get and run SQL scripts from disk.''' self.onecmd(self.query_load10g) + def do_hello(self, arg): + print 'Hello, World!' + @options([make_option('-u', '--uppercase', action='store_true', help='use ALL CAPS')]) - def do_greet(self, args, opts): - ''' - Documentation for the command goes into this string - at the beginning of the method. - ''' - result = 'Hello' - for name in args.split(): - result += ',' + name - result += '!\n' + def do_greet(self, arg, opts): + 'Provides a personalized greeting.' + result = 'Hello %s!\n' % arg if opts.uppercase: result = result.upper() self.stdout.write(result)