* add support for finding related messages to mu-find, mu4e, this does *not*

include the actual implementation though
This commit is contained in:
djcb
2012-12-25 11:58:32 +02:00
parent 3dc1e989ce
commit 58f5e39d34
7 changed files with 45 additions and 18 deletions

View File

@ -129,6 +129,8 @@ run_query (MuQuery *xapian, const gchar *query, MuConfig *opts, GError **err)
qflags |= MU_QUERY_FLAG_DESCENDING;
if (opts->skip_dups)
qflags |= MU_QUERY_FLAG_SKIP_DUPS;
if (opts->include_related)
qflags |= MU_QUERY_FLAG_INCLUDE_RELATED;
iter = mu_query_run (xapian, query, sortid, -1, qflags, err);
return iter;

View File

@ -874,6 +874,8 @@ get_find_params (GSList *args, MuMsgFieldId *sortfield,
*qflags |= MU_QUERY_FLAG_DESCENDING;
if (get_bool_from_args (args, "skip-dups", TRUE, NULL))
*qflags |= MU_QUERY_FLAG_SKIP_DUPS;
if (get_bool_from_args (args, "include-related", TRUE, NULL))
*qflags |= MU_QUERY_FLAG_INCLUDE_RELATED;
return MU_OK;
}

View File

@ -216,6 +216,9 @@ config_options_group_find (void)
{"skip-dups", 'u', 0, G_OPTION_ARG_NONE,
&MU_CONFIG.skip_dups,
"show only the first of messages duplicates (false)", NULL},
{"include-related", 'r', 0, G_OPTION_ARG_NONE,
&MU_CONFIG.include_related,
"include related messages in results (false)", NULL},
{"linksdir", 0, 0, G_OPTION_ARG_STRING, &MU_CONFIG.linksdir,
"output as symbolic links to a target maildir", "<dir>"},
{"clearlinks", 0, 0, G_OPTION_ARG_NONE, &MU_CONFIG.clearlinks,

View File

@ -143,6 +143,8 @@ struct _MuConfig {
* messages with the same
* msgid, show only the first
* one */
gboolean include_related; /* included related messages
* in results */
/* for find and cind */
time_t after; /* only show messages or
* adresses last seen after