]> git.cworth.org Git - notmuch/commit
cli: refactor "notmuch tag" data structures for tagging operations
authorJani Nikula <jani@nikula.org>
Mon, 26 Mar 2012 21:04:09 +0000 (00:04 +0300)
committerDavid Bremner <bremner@debian.org>
Sat, 31 Mar 2012 00:20:36 +0000 (21:20 -0300)
commit8e3ff8fb03dc647f1daea4665c35a2214473ced8
treeae0e9a54e6765e4783f0535127dff044a8d73052
parent918b80359727de2dd87f26a252de8faee2eff78c
cli: refactor "notmuch tag" data structures for tagging operations

To simplify code, keep all tagging operations in a single array
instead of separate add and remove arrays. Apply tag changes in the
order specified on the command line, instead of first removing and
then adding the tags.

This results in a minor functional change: If a tag is both added and
removed, the last specified operation is now used. Previously the tag
was always added. Change the relevant test to reflect the new
behaviour.

Signed-off-by: Jani Nikula <jani@nikula.org>
notmuch-tag.c
test/tagging