From cf3f6e6f3d159448f07958c173f9b0ac06b83073 Mon Sep 17 00:00:00 2001 From: Menno Smits Date: Thu, 8 Nov 2012 13:24:52 +0000 Subject: [PATCH] Fixed command line handling for interact --- imapclient/interact.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/imapclient/interact.py b/imapclient/interact.py index 266fbdc..c6369e9 100644 --- a/imapclient/interact.py +++ b/imapclient/interact.py @@ -18,7 +18,7 @@ def command_line(): help='Username to login with') p.add_option('-p', '--password', dest='password', action='store', help='Password to login with') - p.add_option('-P', '--port', dest='port', action='store', + p.add_option('-P', '--port', dest='port', action='store', type=int, default=None, help='IMAP port to use (default is 143)') p.add_option('-s', '--ssl', dest='ssl', action='store_true', default=False, help='Use SSL connection') @@ -41,7 +41,10 @@ def command_line(): setattr(opts, opt_name, getpass(opt_name + ': ')) if not opts.port: opts.port = 143 - opts.oauth = False # OAUTH not supported on command line + # Options not supported on the command line + opts.oauth = False + opts.oauth2 = False + opts.stream = False return opts def main(): -- 2.43.0