aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* compose: define useful vars in the editor's envJason Cox2023-11-232-0/+13
| | | | | | | | | | | | Add AERC_ACCOUNT and AERC_ADDRESS_BOOK_CMD to the editor's environment when composing a message. These variables allow for per-account configuration of the editor and facilitate address completion when edit-headers = true. Changelog-added: `AERC_ACCOUNT` and `AERC_ADDRESS_BOOK_CMD` are now defined in the editor's environment when composing a message. Signed-off-by: Jason Cox <me@jasoncarloscox.com> Acked-by: Robin Jarry <robin@jarry.cc>
* chore: upgrade to latest tcell-termJason Cox2023-11-232-3/+3
| | | | | | | | | Pull in changes allowing us to specify the environment of the start command for a term. This will allow defining environment variables for the editor in the next commit. Signed-off-by: Jason Cox <me@jasoncarloscox.com> Acked-by: Robin Jarry <robin@jarry.cc>
* maintainers: add inwit and ferdinandybRobin Jarry2023-11-221-1/+10
| | | | | | | | | | | | These folks have been active for quite a while with bug triaging and code review. I have given them moderator access on the mailing lists and on the bug tracker. Thanks guys! Cc: Bence Ferdinandy <bence@ferdinandy.com> Cc: Inwit <inwit@sindominio.net> Signed-off-by: Robin Jarry <robin@jarry.cc>
* mod: update to go-opt@v1.3.0Robin Jarry2023-11-222-3/+3
| | | | | | | | | | | Remove systematic sorting of all completion choices. The choices ordering as reported by callbacks are now preserved. The flags themselves are always at the end in the order in which they are declared in the option struct. Reported-by: Skejg <grolleman@zoho.com> Signed-off-by: Robin Jarry <robin@jarry.cc> Tested-by: Johannes Thyssen Tishman <johannes@thyssentishman.com>
* complete: only display popover for more than one choiceRobin Jarry2023-11-221-64/+74
| | | | | | | | | | When there is only one completion choice available, accept the completion immediately upon a <Tab> key press. This is consistent with how most completion engines work (bash, vim, etc.). Reported-by: Johannes Thyssen Tishman <johannes@thyssentishman.com> Signed-off-by: Robin Jarry <robin@jarry.cc> Tested-by: Johannes Thyssen Tishman <johannes@thyssentishman.com>
* stylesets/nord: make unread selected mails readableMax Schillinger2023-11-121-1/+0
| | | | | | | | Remove the dedicated background color for unread selected e-mails because it's too close to the foreground color. Signed-off-by: Max Schillinger <max@mxsr.de> Acked-by: Robin Jarry <robin@jarry.cc>
* completion: hide quotes from choicesRobin Jarry2023-11-121-3/+10
| | | | | | | | | | | | When completion choices are surrounded by quotes to make sure that they will be interpreted as a single argument, hide them before presenting the choices to the user. It makes the UI cluttered and harder to read. The completion values remain identical, the quotes will be inserted when the user accepts one choice. Signed-off-by: Robin Jarry <robin@jarry.cc> Tested-by: Inwit <inwit@sindominio.net>
* cf: fix over quoting of notmuch queriesRobin Jarry2023-11-121-9/+12
| | | | | | | | | | | | | | | | | | | | | | | | Currently, :cf thread:\{id:{{.MessageId}}\} is broken because it is quoted before being interpreted by notmuch. The dynamic folder is created with this "query" (including the quotes): 'thread:{id:23627381....}' Notmuch queries use the xapian syntax and do not follow basic shell quotes interpretation. Change :cf only argument to preserve the command line as entered by the user without any interpretation. When the backend is notmuch, forward that as the dynamic folder name. For other backends, interpret shell quoting on the user entry and fail if it produces more than one argument. Link: https://xapian.org/docs/queryparser.html Fixes: 6613d9b555be ("cf: fix unexpected argument on notmuch") Reported-by: Inwit <inwit@sindominio.net> Signed-off-by: Robin Jarry <robin@jarry.cc> Tested-by: Inwit <inwit@sindominio.net>
* binds: allow <a-0> to <a-9>Erik Terpstra2023-11-122-0/+30
| | | | | | | | Add support for Alt+<number> keys. Update documentation for it. Changelog-added: Allow binding commands to `Alt+<number>` keys. Signed-off-by: Erik Terpstra <erik@nixhub.nl> Acked-by: Robin Jarry <robin@jarry.cc>
* rmdir: ensure proper sequence of operationsKoni Marti2023-11-124-17/+70
| | | | | | | | | | | | | | | | | | | | Ensure the proper sequence of opening and removing a directory. Fix a potential race between the OpenDirectory (issued by dirlist.Select()) and the RemoveDirectory messages when removing a directory. Due to the delay in the current dirlist.Select() function, the RemoveDirectory message can arrive at the backend before the directory was changed to a different one. This can cause an error on some imap servers and problems with the watcher on the maildir backends. Introduce dirlist.Open() that accepts a callback function so that the operations can be performed in proper sequence. Dirlist.Select() is now a wrapper call to dirlist.Open(). Reported-by: inwit <inwit@sindominio.net> Signed-off-by: Koni Marti <koni.marti@gmail.com> Acked-by: Robin Jarry <robin@jarry.cc> Tested-by: Inwit <inwit@sindominio.net>
* {im,ex}port-mbox: allow using ~ in pathVitaly Ovchinnikov2023-11-122-0/+6
| | | | | | | | Add ~ support to :export-mbox and :import-box the same way as it is done in :save. Signed-off-by: Vitaly Ovchinnikov <v@ovch.ru> Acked-by: Robin Jarry <robin@jarry.cc>
* ui: correct some push status messagesinwit2023-11-124-4/+31
| | | | | | | | | | | Upon success, commands :delete, :copy, :archive and :move show "Messages deleted/copied/archived/moved" in the status bar, which is obviously wrong if they are acting upon only one message. Make the success notification for those commands explicitly agree with the actual number of messages. Signed-Off-By: inwit <inwit@sindominio.net> Acked-by: Robin Jarry <robin@jarry.cc>
* threads: add .ThreadUnread to template datainwit2023-11-125-5/+31
| | | | | | | | | | | | | | | | | When a thread is folded, it can be useful to know how many unseen messages lie below the root. For example, one might want to show that count in the message list: column-folded = {{if .ThreadFolded \ }}{{if ne .ThreadUnread 0 \ }}{{.ThreadUnread | printf "%s/"}}{{ \ end}}{{ .ThreadCount | printf "%s"}}{{end}} Add `.ThreadUnread` to the template functions. Changelog-added: `.ThreadUnread` is now available in templates. Signed-off-by: inwit <inwit@sindominio.net> Acked-by: Robin Jarry <robin@jarry.cc>
* search: add rcpts fields to header in search criteriaKoni Marti2023-11-123-1/+20
| | | | | | | | | | | Add recipients fields (from, to, cc) to the header for filtering and searching for the maildir and mbox backends. Fixes: commit 8464b373 ("search: use a common api for all workers") Reported-by: Vitaly Ovchinnikov <v@ovch.ru> Signed-off-by: Koni Marti <koni.marti@gmail.com> Acked-by: Robin Jarry <robin@jarry.cc> Tested-by: Vitaly Ovchinnikov <v@ovch.ru>
* linters: avoid crash when analyzing function callRobin Jarry2023-11-022-19/+52
| | | | | | | | | | | | | | | | | | | | | When encountering a statement such as: go functionName() The identifier is not a local symbol but should be looked up in the current package. Do not consider that all these statements will refer to local variables. The only way to do this is to run a second analyzer that depends on the first one. Store all unresolved methods and functions into a indirectCalls struct. Reuse that result in the second analyzer to resolve the function declarations and check their bodies for the defer log.PanicHandler() statement. Fix one newly reported issues. Signed-off-by: Robin Jarry <robin@jarry.cc> Reviewed-by: Tim Culverhouse <tim@timculverhouse.com>
* complete: allow disabling automatic completionRobin Jarry2023-11-024-1/+23
| | | | | | | | | | | Allow setting complete-min-chars = manual to disable automatic completion. Changelog-added: Setting `complete-min-chars=manual` in `aerc.conf` now disables automatic completion, leaving only manually triggered completion. Signed-off-by: Robin Jarry <robin@jarry.cc> Reviewed-by: Tim Culverhouse <tim@timculverhouse.com>
* complete: allow setting the completion key bindingRobin Jarry2023-11-026-28/+47
| | | | | | | | | | | | | | | | | | | | | Until now, if less than complete-min-chars were entered or if completion-delay had not expired yet, the only way to force trigger completion was to press <tab>. In some cases, <tab> is already bound to another action (for example :next-field in the compose::editor context). This makes forcing the completion impossible. Allow defining a key to trigger manual completion via the new $complete special entry in binds.conf. Leave the default binding to <tab>. Set it to <C-o> in the [compose::editor] to avoid conflicting with the existing <tab> binding. Changelog-added: Customize key to trigger completion with `$complete` in `binds.conf`. Signed-off-by: Robin Jarry <robin@jarry.cc> Reviewed-by: Tim Culverhouse <tim@timculverhouse.com>
* cf: do not quote notmuch queries in completion resultsRobin Jarry2023-11-021-1/+15
| | | | | | | | | | Notmuch queries should not be quoted, they will be interpreted by the notmuch library. Make sure not to return quoted results for directories which have the role == "query". Reported-by: Inwit <inwit@sindominio.net> Signed-off-by: Robin Jarry <robin@jarry.cc> Tested-by: Inwit <inwit@sindominio.net>
* completion: refactor filter list apiRobin Jarry2023-11-0217-36/+45
| | | | | | | | | | | | Remove CompletionFromList which is a trivial wrapper around FilterList. Remove the prefix, suffix and isFuzzy arguments from FilterList. Replace prefix, suffix by an optional callback to allow post processing of completion results before presenting them to the user. Signed-off-by: Robin Jarry <robin@jarry.cc> Tested-by: Inwit <inwit@sindominio.net>
* hooks: add mail-added hookJason Cox2023-11-029-60/+151
| | | | | | | | | | | | | | The mail-added hook runs whenever a message is added to a folder. Note that the hook does not run when a new message is received (the mail-received hook already covers that) but instead runs whenever aerc itself adds a message to a folder, e.g. when moving or copying a message. Changelog-added: `mail-added` hook that triggers when a message is added to a folder. References: https://todo.sr.ht/~rjarry/aerc/136 Signed-off-by: Jason Cox <me@jasoncarloscox.com> Acked-by: Robin Jarry <robin@jarry.cc>
* hooks: add mail-deleted hookJason Cox2023-11-027-13/+69
| | | | | | | | | | | | The mail-deleted hook runs whenever a message is deleted from a folder. Note that this means moving a message from one folder to another triggers the mail-deleted hook. Changelog-added: `mail-deleted` hook that triggers when a message is removed/moved from a folder. References: https://todo.sr.ht/~rjarry/aerc/136 Signed-off-by: Jason Cox <me@jasoncarloscox.com> Acked-by: Robin Jarry <robin@jarry.cc>
* binds: folder-specific bindings for composerVitaly Ovchinnikov2023-11-023-5/+20
| | | | | | | | | Add folder-specific bindings for composer, so custom binginds might be specified for a composer opened in a given folder. Changlelog-Added: `[compose::editor:folder=$name]` binding context. Signed-off-by: Vitaly Ovchinnikov <v@ovch.ru> Acked-by: Robin Jarry <robin@jarry.cc>
* fold: add an option to toggle foldinginwit2023-11-025-18/+37
| | | | | | | | | | Add a toggle option (-t) to :fold/:unfold commands to allow for switching the folding status of a thread. Changelog-Added: Toggle folding with `:fold -t`. Signed-Off-By: inwit <inwit@sindominio.net> Acked-by: Robin Jarry <robin@jarry.cc> Tested-by: Jason Cox <me@jasoncarloscox.com>
* fold: allow for multiple folding levelsinwit2023-11-026-17/+38
| | | | | | | Extend the :fold/:unfold behaviour to allow for multiple folding levels. Signed-Off-By: inwit <inwit@sindominio.net> Acked-by: Robin Jarry <robin@jarry.cc>
* doc: fix newlines for the aerc-search manpageVitaly Ovchinnikov2023-11-021-2/+2
| | | | | | | Fix newlines in aerc-search manpage to make it more readable. Signed-off-by: Vitaly Ovchinnikov <v@ovch.ru> Acked-by: Robin Jarry <robin@jarry.cc>
* binds: remove duplicated and empty bindingsVitaly Ovchinnikov2023-11-022-0/+61
| | | | | | | | | | | | | Add keybindings filtering, so if the context binding is defined, the parent one is removed and is not shown in the list at all. Also add keybinding removing, so if the context defines an empty binding, both this and parent one are removed from the list. This way you can disable and hide specific bindings in contexts. Changelog-added: Disable parent context bindings by declaring them empty. Signed-off-by: Vitaly Ovchinnikov <v@ovch.ru> Acked-by: Robin Jarry <robin@jarry.cc>
* docs: add examples for modifying column-nameJens Grassel2023-11-021-0/+8
| | | | | | | | | | Add two examples for modifying the column-name template to show the recipient (To field) instead of the sender which might be handy for sent emails. Signed-off-by: Jens Grassel <jens@wegtam.com> Acked-by: Robin Jarry <robin@jarry.cc> Reviewed-by: Inwit <inwit@sindominio.net>
* cf: fix unexpected argument on notmuchRobin Jarry2023-10-301-3/+21
| | | | | | | | | | | | | | Notmuch supports creating "dynamic" folders with the :cf command. When the backend is notmuch, :cf must accept multiple arguments since it can be a free-form notmuch query. Detect if the backend is notmuch and build a quoted query based on the provided arguments. Otherwise require a single argument. Fixes: e54486ee40c9 ("commands: parse arguments with go-opt") Reported-by: Inwit <inwit@sindominio.net> Signed-off-by: Robin Jarry <robin@jarry.cc> Tested-by: Inwit <inwit@sindominio.net>
* complete: add trailing space after quotesRobin Jarry2023-10-301-2/+2
| | | | | | | | | | | | Currently, completing `:tag +forw` gives: '+forwarded ' instead of simply +forwarded without quotes with an embedded trailing space. Add the suffix *after* quoting. Fixes: abe228b14d97 ("commands: use completion from go-opt") Reported-by: Inwit <inwit@sindominio.net> Signed-off-by: Robin Jarry <robin@jarry.cc> Tested-by: Inwit <inwit@sindominio.net>
* treewide: replace shlex.Split with opt.SplitArgsRobin Jarry2023-10-285-19/+7
| | | | | | | | | | Replace the remaining shlex.Split calls with opt.SplitArgs. Remove dependency to shlex. Signed-off-by: Robin Jarry <robin@jarry.cc> Reviewed-by: Koni Marti <koni.marti@gmail.com> Tested-by: Moritz Poldrack <moritz@poldrack.dev> Tested-by: Inwit <inwit@sindominio.net>
* commands: use completion from go-optRobin Jarry2023-10-2881-968/+197
| | | | | | | | | | | Implement command completion with complete struct field tags from the get-opt library introduced earlier. Changelog-changed: Improved command completion. Signed-off-by: Robin Jarry <robin@jarry.cc> Reviewed-by: Koni Marti <koni.marti@gmail.com> Tested-by: Moritz Poldrack <moritz@poldrack.dev> Tested-by: Inwit <inwit@sindominio.net>
* commands: remove command set completion apiRobin Jarry2023-10-283-61/+42
| | | | | | | | | | | Do not expose the completion of a command via its command set. Instead, require a single command object to be resolved in order to execute it. Extract the command names and the template terms completions in main.go. Signed-off-by: Robin Jarry <robin@jarry.cc> Reviewed-by: Koni Marti <koni.marti@gmail.com> Tested-by: Moritz Poldrack <moritz@poldrack.dev> Tested-by: Inwit <inwit@sindominio.net>
* pipe: run commands with sh -cRobin Jarry2023-10-283-15/+19
| | | | | | | | | | | | Change the Cmd argument to a plain string that preserves shell quoting. Use this for sh -c instead of a list of arguments. Changelog-changed: `:pipe` commands are now executed with `sh -c`. Requested-by: Vitaly Ovchinnikov <v@postbox.nz> Signed-off-by: Robin Jarry <robin@jarry.cc> Reviewed-by: Koni Marti <koni.marti@gmail.com> Tested-by: Moritz Poldrack <moritz@poldrack.dev> Tested-by: Inwit <inwit@sindominio.net>
* open: run commands with sh -cRobin Jarry2023-10-288-38/+30
| | | | | | | | | | | Allow running shell commands in openers. Changelog-changed: `:open` commands are now executed with `sh -c`. Requested-by: Vitaly Ovchinnikov <v@postbox.nz> Signed-off-by: Robin Jarry <robin@jarry.cc> Reviewed-by: Koni Marti <koni.marti@gmail.com> Tested-by: Moritz Poldrack <moritz@poldrack.dev> Tested-by: Inwit <inwit@sindominio.net>
* search: use a common api for all workersRobin Jarry2023-10-2821-740/+544
| | | | | | | | | | | | | | | | | | | | | | | | | | Define a SearchCriteria structure. Update the FetchDirectoryContents, FetchDirectoryThreaded and SearchDirectory worker messages to include this SearchCriteria structure instead of a []string slice. Parse the search arguments in a single place into a SearchCriteria structure and use it to search/filter via the message store. Update all workers to use that new API. Clarify the man page indicating that notmuch supports searching with aerc's syntax and also with notmuch specific syntax. getopt is no longer needed, remove it from go.mod. NB: to support more complex search filters in JMAP, we need to use an email.Filter interface. Since GOB does not support encoding/decoding interfaces, store the raw SearchCriteria and []SortCriterion values in the cached FolderContents. Translate them to JMAP API objects when sending an email.Query request to the server. Signed-off-by: Robin Jarry <robin@jarry.cc> Reviewed-by: Koni Marti <koni.marti@gmail.com> Tested-by: Moritz Poldrack <moritz@poldrack.dev> Tested-by: Inwit <inwit@sindominio.net>
* worker: move shared code to libRobin Jarry2023-10-2819-98/+116
| | | | | | | | | | | | | Avoid importing code from worker/lib into lib. It should only be the other way around. Move the message parsing code used by maildir, notmuch, mbox and the eml viewer into a lib/rfc822 package. Adapt imports accordingly. Signed-off-by: Robin Jarry <robin@jarry.cc> Reviewed-by: Koni Marti <koni.marti@gmail.com> Tested-by: Moritz Poldrack <moritz@poldrack.dev> Tested-by: Inwit <inwit@sindominio.net>
* main: parse command line args with go-optRobin Jarry2023-10-282-36/+73
| | | | | | | | | | | | | Use get-opt to make argument parsing more explicit and have automatic usage generation. Update the man page to include missing details. Add a -h flag to display verbose usage and descriptions of options. Signed-off-by: Robin Jarry <robin@jarry.cc> Reviewed-by: Koni Marti <koni.marti@gmail.com> Tested-by: Moritz Poldrack <moritz@poldrack.dev> Tested-by: Inwit <inwit@sindominio.net>
* commands: parse arguments with go-optRobin Jarry2023-10-2875-1346/+673
| | | | | | | | | | | | | | | | | | | | | | | | | | Use the argument parsing framework introduced earlier to unify the parsing of (almost) all command options. Remove custom parsing code and to avoid extraneous types, add fields with `opt` tags on command structs that have options and arguments. Commands that take no argument do not need anything. Since the command objects now carry data, create a new temporary instance of them before passing them to opt.ArgsToStruct when executing a command. A few of the commands use specific semantics for parsing (:choose), or are delegating argument parsing to another function (:sort, :search, :filter). For these commands, simply add a dummy "-" passthrough argument. Since all commands still have the argument list (after split) nothing needs to be changed in this area. There should be no functional change besides the Usage strings and reported errors which are now generated automatically. Signed-off-by: Robin Jarry <robin@jarry.cc> Reviewed-by: Koni Marti <koni.marti@gmail.com> Tested-by: Moritz Poldrack <moritz@poldrack.dev> Tested-by: Inwit <inwit@sindominio.net>
* commands: remove command set execute apiRobin Jarry2023-10-282-44/+30
| | | | | | | | | | Do not expose the execution of a command via its command set. Instead, require a single command object to be resolved in order to execute it. Signed-off-by: Robin Jarry <robin@jarry.cc> Reviewed-by: Koni Marti <koni.marti@gmail.com> Tested-by: Moritz Poldrack <moritz@poldrack.dev> Tested-by: Inwit <inwit@sindominio.net>
* commands: expand templates before command resolutionRobin Jarry2023-10-282-21/+14
| | | | | | | | Move the template expansion before the command name is looked up. It saves a few void renderings and will be required for the next commits. Signed-off-by: Robin Jarry <robin@jarry.cc> Tested-by: Inwit <inwit@sindominio.net>
* commands: pass raw command line down to template evaluationRobin Jarry2023-10-2811-193/+60
| | | | | | | | | | | | | | | | | | | | | | | | Some commands need to invoke others and/or run shell commands. For this, we need the raw command line as entered by the user. Pass it down the call chain just before it is split to invoke the command Execute method. Remove unit tests for the template expand() test which does have any added value now that it is performed on a single string without any quote juggling. Update all code to handle a single string instead of a list of arguments. Introduce a new dependency on git.sr.ht/~rjarry/go-opt to deal with shell splitting. This is in preparation for using opt.ArgsToStruct to parse arguments for all aerc commands. There should be no functional change after this patch. Signed-off-by: Robin Jarry <robin@jarry.cc> Reviewed-by: Koni Marti <koni.marti@gmail.com> Tested-by: Moritz Poldrack <moritz@poldrack.dev> Tested-by: Inwit <inwit@sindominio.net>
* lib: remove unused ShellQuote functionRobin Jarry2023-10-281-17/+0
| | | | | | | | | This function is not used anywhere. Remove it. Signed-off-by: Robin Jarry <robin@jarry.cc> Reviewed-by: Koni Marti <koni.marti@gmail.com> Tested-by: Moritz Poldrack <moritz@poldrack.dev> Tested-by: Inwit <inwit@sindominio.net>
* compose: fix crash when getting hostnameMoritz Poldrack2023-10-261-0/+5
| | | | | | | | | | | | | Currently we assume that a From: address is present when retrieving the hostname for the message ID. This results in an index-out-of-range error when no From address is present. Generate a random hostname for the message ID, if no From: address is present. Fixes: 608bc4fa7fa7 ("compose: use email domain name in Message-Id") Signed-off-by: Moritz Poldrack <git@moritz.sh> Acked-by: Robin Jarry <robin@jarry.cc>
* aerc: initialise the random number generatorMoritz Poldrack2023-10-261-0/+5
| | | | | | | | Add an init function to the main package that seeds the RNG with based on the current time. Signed-off-by: Moritz Poldrack <git@moritz.sh> Acked-by: Robin Jarry <robin@jarry.cc>
* compose: fix header navigation after :compose -eRobin Jarry2023-10-251-9/+4
| | | | | | | | | | | | | | | | | | When the terminal is closed with [compose].edit-headers=true, all headers are deleted and recreated based on the email content. Since the terminal is not active, adding the first header was working fine, but the next ones were replacing the single entry on each call of addEditor(). Fix the broken append() logic. Reported-by: Inwit <inwit@sindominio.net> Fixes: c2a4fc7fdfae ("compose: avoid panic when deleting the last header") Changelog-fixed: Selection of headers in composer after `:compose -e` followed by `:edit -E`. Signed-off-by: Robin Jarry <robin@jarry.cc> Tested-by: Inwit <inwit@sindominio.net>
* commands: add :suspendNojus Gudinavičius2023-10-245-0/+64
| | | | | | | | | Add :suspend to suspend the aerc process, returning to shell. Include documentation and default Ctrl-z keybinding for it. Changelog-added: New `:suspend` command bound to `<C-z>` by default. Signed-off-by: Nojus Gudinavičius <nojus.gudinavicius@gmail.com> Signed-off-by: Robin Jarry <robin@jarry.cc>
* changelog: get unreleased entries from commit trailersRobin Jarry2023-10-234-17/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Asking contributors to update the CHANGELOG.md file is causing lots of merge conflicts. Introduce a new workflow where contributors can attach changelog entries in patches via git trailers. Changelog-added: For new features. Changelog-fixed: For bug fixes. Changelog-changed: For behaviour or config format changes. Changelog-deprecated: For deprecation or removal of functionality. If a complete trailer is longer than 72 characters, it can be continued by indenting extra lines with a single space. The trailer text must be valid markdown. Update CONTRIBUTING.md with new guidelines. Update contrib/release.sh to extract these trailers before tagging and create a new section in CHANGELOG.md. Extract unreleased entries in this commit to follow the new workflow. Changelog-added: New `flagged` criteria for `:sort`. Changelog-added: New `:send-keys` command to control embedded terminals. Changelog-added: Account aliases now support fnmatch-style wildcards. Changelog-fixed: `colorize` support for wildcards `?` and `*`. Signed-off-by: Robin Jarry <robin@jarry.cc> Acked-by: Moritz Poldrack <moritz@poldrack.dev>
* export-mbox: preserve the user-visible sorting order when exportingVitaly Ovchinnikov2023-10-221-6/+47
| | | | | | | | Export messages to mbox format in the same order as they are displayed to the user. Both marked-only and "full" export modes are supported. Signed-off-by: Vitaly Ovchinnikov <v@postbox.nz> Acked-by: Robin Jarry <robin@jarry.cc>
* accounts: allow fnmatch-style wildcards in aliasesJason Cox2023-10-225-40/+48
| | | | | | | | | | | | | | | | | Wildcard aliases make it possible to always reply from the same address to which a message was addressed, which is useful for catch-all email domains. Support fnmatch-style wildcards in only the address portion of an alias. When replying to a message that matches a wildcard alias, substitute the matching email address for the wildcard address, but keep the name specified with the wildcard address. For example, when the alias "Someone Awesome" <*@someone.com> is present, the reply to an email addressed to "Someone" <hi@someone.com> would be from "Someone Awesome" <hi@someone.com>. Signed-off-by: Jason Cox <me@jasoncarloscox.com> Acked-by: Robin Jarry <robin@jarry.cc>
* config: ensure account order as requestedKoni Marti2023-10-221-1/+5
| | | | | | | | | | | | Ensure the account order as requested by the -a option on the command line. The current sorting is not working correctly, since it sorts Accounts []*AccountConfig by comparing the names instead of the indexes of the requested accounts. Fixes: https://todo.sr.ht/~rjarry/aerc/190 Signed-off-by: Koni Marti <koni.marti@gmail.com> Tested-by: Inwit <inwit@sindominio.net> Acked-by: Robin Jarry <robin@jarry.cc>