summaryrefslogtreecommitdiffstats
path: root/pykolab/cli
diff options
context:
space:
mode:
authorJeroen van Meeuwen (Kolab Systems) <vanmeeuwen@kolabsys.com>2014-01-15 15:40:45 +0100
committerJeroen van Meeuwen (Kolab Systems) <vanmeeuwen@kolabsys.com>2014-01-15 15:41:18 +0100
commit4829b270a75abd929a8897559bcb1610e847417e (patch)
treeb610fa4abe7790c05a980b95945cb13900fdb27f /pykolab/cli
parent3a69f985de5401a1493a65bde27b0cbb5a7abf31 (diff)
downloadpykolab-4829b270a75abd929a8897559bcb1610e847417e.tar.gz
Add the option for partition to rename-mailbox
Diffstat (limited to 'pykolab/cli')
-rw-r--r--pykolab/cli/cmd_rename_mailbox.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/pykolab/cli/cmd_rename_mailbox.py b/pykolab/cli/cmd_rename_mailbox.py
index e596401..43fae96 100644
--- a/pykolab/cli/cmd_rename_mailbox.py
+++ b/pykolab/cli/cmd_rename_mailbox.py
@@ -44,6 +44,10 @@ def execute(*args, **kw):
source_folder = conf.cli_args.pop(0)
try:
target_folder = conf.cli_args.pop(0)
+ try:
+ partition = conf.cli_args.pop(0)
+ except IndexError, errmsg:
+ partition = None
except IndexError, errmsg:
print >> sys.stderr, _("No target mailbox name specified")
except IndexError, errmsg:
@@ -66,5 +70,5 @@ def execute(*args, **kw):
print >> sys.stderr, _("Target folder %r already exists") % (target_folder)
sys.exit(1)
- imap.user_mailbox_rename(source_folder.replace('user/',''), target_folder.replace('user/',''))
+ imap.user_mailbox_rename(source_folder.replace('user/',''), target_folder.replace('user/',''), partition=partition)