    # File lib/vmail/imap_client.rb, line 729
        def save_attachments(dir)
          log "save_attachments #{dir}"
          if !@current_mail
            log "missing a current message"
          end
          return unless dir && @current_mail
          attachments = @current_mail.attachments
          `mkdir -p #{dir}`
          saved = attachments.map do |x|
            path = File.join(dir, x.filename)
            log "saving #{path}"
            File.open(path, 'wb') {|f| f.puts x.decoded}
            path
          end
          "saved:\n" + saved.map {|x| "- #{x}"}.join("\n")
        end