From e83c4515e0179221e7315abb606452ab2f7b561d Mon Sep 17 00:00:00 2001 From: Paul Iannetta Date: Thu, 21 Apr 2022 23:53:31 +0200 Subject: add partial mutt config --- .config/mutt/mailboxes.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100755 .config/mutt/mailboxes.py (limited to '.config/mutt/mailboxes.py') diff --git a/.config/mutt/mailboxes.py b/.config/mutt/mailboxes.py new file mode 100755 index 0000000..1538122 --- /dev/null +++ b/.config/mutt/mailboxes.py @@ -0,0 +1,12 @@ +import sys +import json + +account = str(sys.argv[1]) + +mailboxes = [] +with open('/home/lys/.offlineimap/mbnames/{}.json'.format(account), 'r') as f: + data = json.load(f) + for folder in data: + mailboxes.append('"+{}/{}"'.format(account,folder['foldername'])) + +print('{}'.format(' '.join(mailboxes))) -- cgit v1.2.3-54-g00ecf