]> git.cworth.org Git - notmuch/commit
cli: tell how many messages were precisely matched when expected 1 match
authorTomi Ollila <tomi.ollila@iki.fi>
Sat, 7 May 2016 19:24:18 +0000 (22:24 +0300)
committerDavid Bremner <david@tethera.net>
Thu, 19 May 2016 10:49:03 +0000 (07:49 -0300)
commiteac29763896e457a738f811b2c2ba8f877498e62
tree2d023cc97efd77575943404645f04c5cf90201c7
parent2ee9351224a940eff65c6aa73ad8befab48250f9
cli: tell how many messages were precisely matched when expected 1 match

In case of notmuch reply and notmuch show --part=N it is required that
search terms match to one message. If match count was != 1, error
message "Error: search term did not match precisely one message"
was too vague to explain what happened.

By appending (matched <num> messages) to the error message it
makes the problem more understandable (e.g when <num> is '0'
user reckons the query had a typo in it).
notmuch-reply.c
notmuch-show.c
test/T210-raw.sh