1
0
mirror of https://github.com/djcb/mu.git synced 2024-06-20 06:46:50 +02:00
Commit Graph

326 Commits

Author SHA1 Message Date
Dirk-Jan C. Binnema
0e50bfc02c mu: better output
Improve the output of various mu commands
2020-06-27 17:07:00 +03:00
Dirk-Jan C. Binnema
63a8c72b74 config: add message-size, batch-size option for init 2020-06-27 11:36:34 +03:00
Dirk-Jan C. Binnema
c8e8004f29 server: show complete help by default
And add :terse to get a one-line description.
2020-06-27 10:24:37 +03:00
Dirk-Jan C. Binnema
68533cee0d mu: use g_printerr for errors, instead of g_warning
With the new logging setup, we need g_printerr
2020-06-13 16:56:41 +03:00
Dirk-Jan C. Binnema
9b2746dce5 server: use symbolic names with ':'
After the command-parser changes
2020-06-13 16:56:41 +03:00
Dirk-Jan C. Binnema
3dc4b93989 mu4e/server: implement mark-as-read for (view ...)
Instead of a multi-step process to display an unread message (ie. get
the original, notice it's unread, then update it, replace the message
with update one etc.), we now handle that in the (view /./..) command on
the server side.

Simplifies things, and is faster (which could be noticeable, esp. if
e.g. signature verification is part of the process)
2020-06-13 16:56:41 +03:00
Dirk-Jan C. Binnema
0b427e5ee8 server: use Mu::Store in c++ mode
I.e. Mu::Store instead of mu_store_*
2020-06-13 16:56:41 +03:00
Dirk-Jan C. Binnema
a9fab4abcc mu: convert command-line tools to c++ 2020-06-13 16:56:41 +03:00
Dirk-Jan C. Binnema
87eff66b7d test-mu-cmd: temporarily turn off test 2020-06-11 21:49:55 +03:00
Dirk-Jan C. Binnema
9fa09f2c16 server: use sexp builder for return parameters
Generate sexps programmatically rather than with string-formatting,
using the new mu-sexp capabilities.
2020-06-06 14:27:25 +03:00
Dirk-Jan C. Binnema
3afdc08d50 lib/utils: build s-expression programmatically building
Allow for programmatically buildings sexps, rather that using raw
strings.
2020-06-06 14:27:25 +03:00
Dirk-Jan C. Binnema
3e233cba9a rework logging system
reimplement the old mu-log.[ch] into mu-logging.{cc,hh}

If available (and using an appropriately equipped glib), log to the
systemd journal

Only g_criticals have stderr output, all the other g_* go to the log
file / journal.
2020-05-30 13:29:44 +03:00
Dirk-Jan C. Binnema
b60cfc7df2 mu-server: restore readline-support
Restore readline support for `mu server' (but _only_ when readline is
found and when in tty mode)
2020-05-25 18:34:42 +03:00
Dirk-Jan C. Binnema
53b553124c
Merge pull request #1663 from czan/master
mu: always sort descending within threads
2020-05-17 14:45:39 +03:00
Jonas Bernoulli
564d892701 Fix typos 2020-05-12 23:56:55 +02:00
Dirk-Jan C. Binnema
55cac6f2e5 mu-server: disable readline support for now
Seems to be causing problem in non-interactive mode
2020-05-11 22:04:01 +03:00
Dirk-Jan C. Binnema
f3b70bf049 mu: support --eval for server testing
Add a hidden command-line argument, just for testing.
2020-05-05 21:24:37 +03:00
Carlo Zancanaro
928dc5e0fc mu: always sort descending within threads 2020-04-29 10:55:19 +10:00
Dirk-Jan C. Binnema
06d3deb4cc guile: path updates for 2.2 2020-04-20 00:01:07 +03:00
Dirk-Jan C. Binnema
2da1ddbd56 mu/config: properly close the config group 2020-04-19 22:24:44 +03:00
Dirk-Jan C. Binnema
46ae663937 mu4e: use faster count queries, document differences
Use faster queries for counting read/unread messages; document why the
results might differ from what you get doing a normal search.
2020-03-15 01:23:01 +02:00
Dirk-Jan C. Binnema
1d14b82595 mu index: remove duplicate cmdline parameter 2020-03-02 23:18:58 +02:00
Dirk-Jan C. Binnema
f0a0c3ad46 server: reinstate readline support (when available) 2020-03-01 02:08:23 +02:00
damon-kwok
56b434347e error fix for gcc 9.x 2020-02-29 20:40:22 +08:00
Dirk-Jan C. Binnema
36a5d291d9 server/mu4e: update decrypt/verify options
"extract-encrypted" -> "decrypt"

and a separate option for "verify"
2020-02-28 00:43:08 +02:00
Dirk-Jan C. Binnema
4226a6e47f server: better readline check
Avoid _partial_ setups.

Fixes #1594.
2020-02-27 18:55:08 +02:00
Dirk-Jan C. Binnema
0e75f84228 server/find: handle maxnum correctly
If it's nil, use '-1' so we get unlimited results.

Fixes #1592.
2020-02-26 19:32:53 +02:00
Dirk-Jan C. Binnema
06c9b17a4e mu: remove mfind command
Better document what find does instead.
2020-02-24 21:18:54 +02:00
Dirk-Jan C. Binnema
adbb57c098 server: enable repl history 2020-02-21 19:19:30 +02:00
Dirk-Jan C. Binnema
ed1fcda81a server: use MU_QUERY_FLAG_SKIP_UNREADABLE by default 2020-02-21 01:42:37 +02:00
Dirk-Jan C. Binnema
8d6d151090 server: support readline history / persistence
When using readline, remember the last 50 commands; persist.
2020-02-21 01:17:23 +02:00
Dirk-Jan C. Binnema
000c19e505 server: improve error message 2020-02-18 12:03:42 +02:00
Dirk-Jan C. Binnema
6b07819d9a mu4e/mu-server: use :descending, :no-view parameters
There was some confusion between mu4e and mu-server.
2020-02-18 12:03:42 +02:00
Dirk-Jan C. Binnema
62cc675a51 server: explicitly flush after indexing 2020-02-15 18:26:45 +02:00
Dirk-Jan C. Binnema
10fa0727ef server: clear up move_docid
Ensure all paths free resources
2020-02-15 14:12:21 +02:00
Dirk-Jan C. Binnema
a4a682e578 mu: add memcheck script for valgrinding 2020-02-15 14:09:30 +02:00
Dirk-Jan C. Binnema
c22eb434b7 mu: improve crypto handling 2020-02-14 00:36:54 +02:00
Dirk-Jan C. Binnema
b77b536d81
Merge pull request #1444 from JulienMasson/threads-sorting
mu: add an option to ignore leader when sorting childs of a thread
2020-02-10 21:58:33 +02:00
Dirk-Jan C. Binnema
d90d2ce8ef mu/mu4e: pass muhome to server (and provide some better error info) 2020-02-10 18:07:54 +02:00
Julien Masson
c4ccaf0fdb mu: sort childs of thread based on the sortfield only
Today when we query a find cmd with the `--threads` option, all the
childs of each thread are sorted according to their leader based on
the sortfield.

This patch change the way of how the childs of a thread are sorted.
The threads are still sorted according to their leader but all the
childs of each thread are now sorted based on the sortfield only.

Here is an example of what happened with the previous sorting:

Example with random kernel thread sorted by date:

[PATCH 0/4] drm/panel: jh057n0090: Add regulators and drop magic value in init
  ┣━▶[PATCH 1/4] MAINTAINERS: Add Purism mail alias as reviewer for their devkit's panel
  ┣━▶[PATCH 2/4] drm/panel: jh057n0090: Don't use magic constant
  ┣━▶[PATCH 3/4] dt-bindings: display/panel: jh057n0090: Document power supply properties
  ┗━▶[PATCH 4/4] drm/panel: jh057n0090: Add regulator support

If someone reply to one of these emails in the middle, this email
become the leader and the thread is displayed like this:

[PATCH 0/4] drm/panel: jh057n0090: Add regulators and drop magic value in init
  ┣━▶[PATCH 2/4] drm/panel: jh057n0090: Don't use magic constant
  ┃  ┗━▶ Re: [PATCH 2/4] drm/panel: jh057n0090: Don't use magic constant
  ┣━▶[PATCH 1/4] MAINTAINERS: Add Purism mail alias as reviewer for their devkit's panel
  ┣━▶[PATCH 3/4] dt-bindings: display/panel: jh057n0090: Document power supply properties
  ┗━▶[PATCH 4/4] drm/panel: jh057n0090: Add regulator support

With this patch, we will have the following output:

[PATCH 0/4] drm/panel: jh057n0090: Add regulators and drop magic value in init
  ┣━▶[PATCH 1/4] MAINTAINERS: Add Purism mail alias as reviewer for their devkit's panel
  ┣━▶[PATCH 2/4] drm/panel: jh057n0090: Don't use magic constant
  ┃  ┗━▶ Re: [PATCH 2/4] drm/panel: jh057n0090: Don't use magic constant
  ┣━▶[PATCH 3/4] dt-bindings: display/panel: jh057n0090: Document power supply properties
  ┗━▶[PATCH 4/4] drm/panel: jh057n0090: Add regulator support

The tests cases concerning threads have also been updated.

Signed-off-by: Julien Masson <massonju.eseo@gmail.com>
2020-02-10 15:42:39 +01:00
Dirk-Jan C. Binnema
36b31eeb0a mu: check --maildir parameter for init
Fixes #1568.
2020-02-09 22:40:57 +02:00
Dirk-Jan C. Binnema
85df5524f3 server: fix typo 2020-02-09 18:07:30 +02:00
Dirk-Jan C. Binnema
876f70d50d mu: update unit tests
They need to use 'mu init' as well.
2020-02-09 18:01:06 +02:00
Dirk-Jan C. Binnema
451309697d server: 'sent' does not use 'maildir' anymore
So don't require it.
2020-02-09 15:07:22 +02:00
Dirk-Jan C. Binnema
4e5f6b4b0a mu: make command output more useful 2020-02-09 00:15:49 +02:00
Dirk-Jan C. Binnema
e1e26d1da2 mu4e: update to use server maildir/database/addresses
Mkae mu4e-maildir and mu4e-personal-addresses obsolete, we get those
from the server.
2020-02-09 00:15:49 +02:00
Dirk-Jan C. Binnema
dea4789e0e server: pass root-maildir, personal-addresses, dbpath to mu4e
Tell mu4e about the parameters, so users do not need to explicitly set
them.
2020-02-09 00:15:49 +02:00
Dirk-Jan C. Binnema
f51846eefc mu: implement init, info commands
'init' is for the inital database setup

'info' is for gettting information about the mu database.
2020-02-08 14:28:55 +02:00
Dirk-Jan C. Binnema
2575b2d0e3 mu: better error handling for opening database read-only
Be a bit clearer for the user.
2020-02-04 21:14:30 +02:00
Dirk-Jan C. Binnema
3fc2a5f3f8 server: re-introduce signal handler
This still needed to be ported from the old server code.
2020-02-04 01:05:35 +02:00