Skip to content

Implement notmuch2 on notmuch mail backend #876

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: current
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions i3pystatus/mail/notmuchmail.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# note that this needs the notmuch python bindings. For more info see:
# http://notmuchmail.org/howto/#index4h2
import notmuch
import notmuch2
import configparser
import os
from i3pystatus.mail import Backend
Expand Down Expand Up @@ -36,8 +36,8 @@ def init(self):

@property
def unread(self):
db = notmuch.Database(self.db_path)
result = notmuch.Query(db, self.query).count_messages()
db = notmuch2.Database(self.db_path)
result = db.count_messages(self.query)
db.close()
return result

Expand Down