From 90f2b47ca59a4401953d93e61f34647e383a5176 Mon Sep 17 00:00:00 2001 From: Yuxin Wu Date: Thu, 21 Jan 2016 00:53:53 -0500 Subject: [PATCH] list chats --- list-chats.py | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100755 list-chats.py diff --git a/list-chats.py b/list-chats.py new file mode 100755 index 0000000..a64a434 --- /dev/null +++ b/list-chats.py @@ -0,0 +1,14 @@ +#!/usr/bin/env python2 +# -*- coding: UTF-8 -*- +# File: list-chats.py +# Author: Yuxin Wu + +from wechat.parser import WeChatDBParser +import sys + +db_file = sys.argv[1] + +parser = WeChatDBParser(db_file) +chats = parser.msgs_by_chat.keys() +for k in chats: + print k.encode('utf-8'), parser.contacts_rev[k].encode('utf-8')