diff options
-rwxr-xr-x | cmd2/cmd2.py | 7 | ||||
-rw-r--r-- | main.py | 12 |
2 files changed, 12 insertions, 7 deletions
diff --git a/cmd2/cmd2.py b/cmd2/cmd2.py index 1c9a3c30..bc3bc089 100755 --- a/cmd2/cmd2.py +++ b/cmd2/cmd2.py @@ -4047,10 +4047,3 @@ class CmdResult(namedtuple_with_two_defaults('CmdResult', ['out', 'err', 'war']) return not self.err -if __name__ == '__main__': - # If run as the main application, simply start a bare-bones cmd2 application with only built-in functionality. - - # Set "use_ipython" to True to include the ipy command if IPython is installed, which supports advanced interactive - # debugging of your application via introspection on self. - app = Cmd(use_ipython=False) - app.cmdloop() diff --git a/main.py b/main.py new file mode 100644 index 00000000..a0539bd0 --- /dev/null +++ b/main.py @@ -0,0 +1,12 @@ +#!/usr/bin/env python +# coding=utf-8 + +from cmd2 import Cmd + +if __name__ == '__main__': + # If run as the main application, simply start a bare-bones cmd2 application with only built-in functionality. + + # Set "use_ipython" to True to include the ipy command if IPython is installed, which supports advanced interactive + # debugging of your application via introspection on self. + app = Cmd(use_ipython=False) + app.cmdloop() |