Currently, when moving files, we move the file in the filesystem and shell out to notmuch new, and pick up new file locations in doing that.
This causes problems, as users often call afew via notmuch's hook system, and in general, it's a bit invasive operation.
A better way would be to do the following on mail move:
- Copy the file to the new location
- Call
notmuch.database.add_message() with the new location
- Remove the file on the old location
- Call
notmuch.database.remove_message() with the old location
This would supersede #187, and fix #139.
Currently, when moving files, we move the file in the filesystem and shell out to
notmuch new, and pick up new file locations in doing that.This causes problems, as users often call
afewvianotmuch's hook system, and in general, it's a bit invasive operation.A better way would be to do the following on mail move:
notmuch.database.add_message()with the new locationnotmuch.database.remove_message()with the old locationThis would supersede #187, and fix #139.