aerc/widgets
Jonathan Bartlett 175d0efeb2 binds: add account specific bindings
When using aerc for multiple accounts often bindings might differ
slightly between accounts. For example:

* Account A archives to one directory (:archive)
* Account B archives to monthly directories (:archive month)

Add account specific bindings to allow the user to add a "context" to a
binding group using a context specifier and a regular expression.

Currently the only context specifier is 'account'.

The regular expression is validated against the accounts loaded from
accounts.conf and the configuration fails to load if there are no
matches.

Contextual bindings are merged with global bindings, with contextual
bindings taking precedence, when that context is active.

Bindings are be configured using a generic pattern of
'view:context=regexp'. E.g.:

    # Globally Applicable Archiving
    [messages]
    A = :read<Enter>:archive<Enter>

    # Monthly Archiving for 'Mailbox' Account
    [messages:account=Mailbox$]
    A = :read<Enter>:archive month<Enter>

In the above example all accounts matching the regular expression will
archive in the monthly format - all others will use the global binding.

Signed-off-by: Jonathan Bartlett <jonathan@jonnobrow.co.uk>
2021-12-11 21:45:41 +01:00
..
account-wizard.go go.mod: change base git url 2021-11-05 10:21:45 +01:00
account.go messages: allow displaying email threads 2021-11-13 15:05:59 +01:00
aerc.go binds: add account specific bindings 2021-12-11 21:45:41 +01:00
common.go go.mod: change base git url 2021-11-05 10:21:45 +01:00
compose.go style: customize vertical and horizontal border characters 2021-11-30 15:05:33 +01:00
dirlist.go notmuch: allow sort by file order 2021-11-13 15:25:04 +01:00
exline.go go.mod: change base git url 2021-11-05 10:21:45 +01:00
getpasswd.go go.mod: change base git url 2021-11-05 10:21:45 +01:00
headerlayout.go go.mod: change base git url 2021-11-05 10:21:45 +01:00
msglist.go messages: allow displaying email threads 2021-11-13 15:05:59 +01:00
msgviewer.go style: customize vertical and horizontal border characters 2021-11-30 15:05:33 +01:00
pgpinfo.go go.mod: change base git url 2021-11-05 10:21:45 +01:00
providesmessage.go go.mod: change base git url 2021-11-05 10:21:45 +01:00
selector.go go.mod: change base git url 2021-11-05 10:21:45 +01:00
spinner.go go.mod: change base git url 2021-11-05 10:21:45 +01:00
status.go go.mod: change base git url 2021-11-05 10:21:45 +01:00
tabhost.go Implement style configuration. 2020-08-06 21:42:06 +02:00
terminal.go go.mod: change base git url 2021-11-05 10:21:45 +01:00