aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xarchivemail12
1 files changed, 6 insertions, 6 deletions
diff --git a/archivemail b/archivemail
index 92faa2a..37b3777 100755
--- a/archivemail
+++ b/archivemail
@@ -1645,16 +1645,16 @@ def make_archive_name(mailbox_name):
if options.archive_suffix:
suffix = time.strftime(options.archive_suffix, tm)
if re.match(r'imaps?://', mailbox_name.lower()):
- archive_dir = ""
- archive_base = mailbox_name.rsplit('/', 1)[-1]
+ archive_head = ""
+ archive_tail = mailbox_name.rsplit('/', 1)[-1]
else:
- archive_dir, archive_base = os.path.split(mailbox_name)
+ archive_head, archive_tail = os.path.split(mailbox_name)
if not prefix:
# Don't create hidden archives, e.g. when processing Maildir++ subfolders
- archive_base = archive_base.lstrip('.')
+ archive_tail = archive_tail.lstrip('.')
if options.output_dir:
- archive_dir = options.output_dir
- archive_name = os.path.join(archive_dir, prefix + archive_base + suffix)
+ archive_head = options.output_dir
+ archive_name = os.path.join(archive_head, prefix + archive_tail + suffix)
return archive_name
def check_sane_destdir(dir):