diff options
| author | Jules Aguillon <juloo.dsi@gmail.com> | 2021-02-17 00:43:16 +0100 |
|---|---|---|
| committer | David Bremner <david@tethera.net> | 2021-04-26 20:20:57 -0300 |
| commit | 0998fa9a09387b622d770fc8c5f780a951b0cf2a (patch) | |
| tree | 54aaaae436044e5f95c3d32032de42ca665bf9c9 /vim/notmuch.vim | |
| parent | c3c74621fa8a6ee2f5ca6a06ca1eb32e20227e65 (diff) | |
Vim: Ensure that every queries respect excluded tags
This makes sure that the bug solved by the previous commit won't happen again
and remove some dupplication.
This shouldn't have any side effect.
Diffstat (limited to 'vim/notmuch.vim')
| -rw-r--r-- | vim/notmuch.vim | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/vim/notmuch.vim b/vim/notmuch.vim index c1c2f63d..8e547d4e 100644 --- a/vim/notmuch.vim +++ b/vim/notmuch.vim @@ -317,9 +317,6 @@ ruby << EOF $curbuf.render do |b| q = $curbuf.query(get_cur_view) q.sort = Notmuch::SORT_OLDEST_FIRST - $exclude_tags.each { |t| - q.add_tag_exclude(t) - } msgs = q.search_messages msgs.each do |msg| m = Mail.read(msg.filename) @@ -643,9 +640,6 @@ ruby << EOF $searches.clear folders.each do |name, search| q = $curbuf.query(search) - $exclude_tags.each { |t| - q.add_tag_exclude(t) - } $searches << search count = count_threads ? q.count_threads : q.count_messages b << "%9d %-20s (%s)" % [count, name, search] @@ -657,9 +651,6 @@ ruby << EOF date_fmt = VIM::evaluate('g:notmuch_date_format') q = $curbuf.query(search) q.sort = Notmuch::SORT_NEWEST_FIRST - $exclude_tags.each { |t| - q.add_tag_exclude(t) - } $threads.clear t = q.search_threads @@ -711,6 +702,9 @@ ruby << EOF def query(*args) q = @db.query(*args) @queries << q + $exclude_tags.each { |t| + q.add_tag_exclude(t) + } q end |
