aboutsummaryrefslogtreecommitdiffstats
path: root/doc
Commit message (Collapse)AuthorAgeFilesLines
...
* hooks: add mail-added hookJason Cox2023-11-021-0/+15
| | | | | | | | | | | | | | 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-021-0/+13
| | | | | | | | | | | | 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-021-2/+8
| | | | | | | | | 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-021-3/+4
| | | | | | | | | | 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>
* 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-021-0/+13
| | | | | | | | | | | | | 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>
* pipe: run commands with sh -cRobin Jarry2023-10-281-4/+4
| | | | | | | | | | | | 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-281-4/+5
| | | | | | | | | | | 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-281-1/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | 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>
* main: parse command line args with go-optRobin Jarry2023-10-281-8/+14
| | | | | | | | | | | | | 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: add :suspendNojus Gudinavičius2023-10-241-0/+3
| | | | | | | | | 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>
* accounts: allow fnmatch-style wildcards in aliasesJason Cox2023-10-221-0/+7
| | | | | | | | | | | | | | | | | 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>
* terminal: add `:send-keys` commandVitaly Ovchinnikov2023-10-221-0/+17
| | | | | | | | | | | | Add a new command for sending keystrokes to the active terminal, if there is one visible. Covers split preview, message viewer, composer and the terminal mode. This can be used to navigate the embedded applications to scroll or safely quit them when needed. Signed-off-by: Vitaly Ovchinnikov <v@postbox.nz> Acked-by: Robin Jarry <robin@jarry.cc>
* doc: update aerc-bindsKoni Marti2023-10-131-12/+6
| | | | | | | | | | Update aerc-binds to reflect the code. The contextual account and folder arguments were always evaluated as regular expressions. Also, the contextual arguments do not understand "~" but only "=" (in contrast to the ui contextual parser). Signed-off-by: Koni Marti <koni.marti@gmail.com> Acked-by: Robin Jarry <robin@jarry.cc>
* doc: rephrase aerc-search -d date selectionMoritz Poldrack2023-10-131-3/+5
| | | | | | | | | | Recent mailing list interaction has shown that the current way of phrasing it reduces the visibility of the default YYYY-MM-DD format. Move the default format to be in line with the alternative formats. Link: https://lists.sr.ht/~rjarry/aerc-discuss/%3CCVZCP9GEMI1K.2F9Z9JIU1GTA2%40schach.ware.local%3E Signed-off-by: Moritz Poldrack <git@moritz.sh> Acked-by: Robin Jarry <robin@jarry.cc>
* sort: new `flagged` sorting criteriaVitaly Ovchinnikov2023-10-131-0/+2
| | | | | | | | | Add new `flagged` criteria to `:sort` command (and apparently to the `sort` config option). Good for moving important stuff up. Signed-off-by: Vitaly Ovchinnikov <v@postbox.nz> Reviewed-by: Koni Marti <koni.marti@gmail.com> Acked-by: Robin Jarry <robin@jarry.cc>
* send: add option to overwrite copy-to folderKoni Marti2023-10-131-1/+3
| | | | | | | | | | | | | | | | Add -t option to specify a folder that will overwrite the default Copy-To folder from accounts.conf. This allows you to keep the sent messages in the desired folder. Use templates to create a keybind and always keep the sent messages in the currently selected folder: :send -t {{.Folder}} Fixes: https://todo.sr.ht/~rjarry/aerc/187 Signed-off-by: Koni Marti <koni.marti@gmail.com> Acked-by: Robin Jarry <robin@jarry.cc> Tested-by: Maarten van Gompel <proycon@anaproy.nl>
* split: add an alias for horizontal splitinwit2023-10-131-5/+6
| | | | | | | | | | To date, there are two orthogonal commands named :vsplit and :split, which create a vertical and a horizontal split, respectively. Add a :hsplit alias for the latter. Signed-Off-By: inwit <inwit@sindominio.net> Acked-by: Robin Jarry <robin@jarry.cc> Reviewed-by: Moritz Poldrack <moritz@poldrack.dev>
* switcher: add scrollbarKoni Marti2023-10-131-0/+8
| | | | | | | | | | | | Add scrollbar to part switcher. Add config value "max-mime-height" to the [Viewer] section to set the maximum height before a scrollbar is drawn. The part switcher height is restricted to half of the context height. Update docs. Fixes: https://todo.sr.ht/~rjarry/aerc/194 Signed-off-by: Koni Marti <koni.marti@gmail.com> Tested-by: Inwit <inwit@sindominio.net> Acked-by: Robin Jarry <robin@jarry.cc>
* doc: document -p option for move/copyKoni Marti2023-10-131-6/+10
| | | | | | | | | | Document the -p option for the :move and :copy commands. The -p flag will create the target folder before moving or copying the selected message(s). Signed-off-by: Koni Marti <koni.marti@gmail.com> Acked-by: Inwit <inwit@sindominio.net> Acked-by: Robin Jarry <robin@jarry.cc>
* widgets: rename package to appRobin Jarry2023-10-101-1/+1
| | | | | | | | | This is the central point of all aerc. Having it named widgets is confusing. Rename it to app. It will make a cleaner transition when making the app.Aerc object available globally in the next commit. Signed-off-by: Robin Jarry <robin@jarry.cc> Acked-by: Moritz Poldrack <moritz@poldrack.dev>
* commands: add :toggle-thread-context commandTim Culverhouse2023-09-271-0/+4
| | | | | | | | | Add a command to toggle the display of an thread-context. Update CHANGELOG. Signed-off-by: Tim Culverhouse <tim@timculverhouse.com> Tested-by: Inwit <inwit@sindominio.net> Acked-by: Robin Jarry <robin@jarry.cc>
* ui: enable showing of thread-contextTim Culverhouse2023-09-271-0/+6
| | | | | | | | | | | | | | | Add a UI config value to enable showing of "thread-context", similar to `notmuch show --entire-thread=true`. Add an associated style called "msglist_thread_context" which can be used to style such messages. Currently this feature is only supported by notmuch. It would be possible for maildir to implement as well, IMAP with gmail custom extensions, and JMAP. This patch merely implements the notmuch version and puts the groundwork in for handling these sorts of displays. Signed-off-by: Tim Culverhouse <tim@timculverhouse.com> Tested-by: Inwit <inwit@sindominio.net> Acked-by: Robin Jarry <robin@jarry.cc>
* docs: add missing newline between :attach variantsRobin Jarry2023-09-191-1/+1
| | | | | | | | Avoid multiple variants of :attach to be rendered on the same line. Fixes: af63bd0188d1 ("doc: homogenize scdoc markup") Signed-off-by: Robin Jarry <robin@jarry.cc> Acked-by: Moritz Poldrack <moritz@poldrack.dev>
* docs: fix typo in stylesets regexp exampleRobin Jarry2023-09-191-2/+2
| | | | | | | | | | The backslashes must be escaped, otherwise they are not rendered by scdoc. Fixes: 2f46f64b0b0b ("styleset: allow dynamic msglist styling") Reported-by: Vitaly Ovchinnikov <v@postbox.nz> Signed-off-by: Robin Jarry <robin@jarry.cc> Acked-by: Moritz Poldrack <moritz@poldrack.dev>
* docs: add msglist_thread_folded style objectRobin Jarry2023-09-191-0/+3
| | | | | | | | This style object was not documented. Make it so. Fixes: 995dfc15a806 ("styles: add style for folded threads") Signed-off-by: Robin Jarry <robin@jarry.cc> Reviewed-by: Bence Ferdinandy <bence@ferdinandy.com>
* docs: add :fold and :unfold commandsRobin Jarry2023-09-191-0/+7
| | | | | | | | These commands were not documented. Make them so. Fixes: 94b1c778dbe6 ("commands: add :fold and :unfold for thread folding") Signed-off-by: Robin Jarry <robin@jarry.cc> Reviewed-by: Bence Ferdinandy <bence@ferdinandy.com>
* docs: add :connect and :disconnect commandsRobin Jarry2023-09-191-0/+5
| | | | | | | | These commands were not documented. Make them so. Fixes: e41ed82cf3db ("imap: add manual {dis,}connect support") Signed-off-by: Robin Jarry <robin@jarry.cc> Reviewed-by: Bence Ferdinandy <bence@ferdinandy.com>
* docs: add :help and :new-account commandsRobin Jarry2023-09-191-0/+11
| | | | | | | These commands were not documented. Make them so. Signed-off-by: Robin Jarry <robin@jarry.cc> Reviewed-by: Bence Ferdinandy <bence@ferdinandy.com>
* docs: add :toggle-key-passthrough commandRobin Jarry2023-09-191-0/+4
| | | | | | | | This command was not documented. Make it so. Fixes: 74366d895d5c ("viewer: add key passthrough mode") Signed-off-by: Robin Jarry <robin@jarry.cc> Reviewed-by: Bence Ferdinandy <bence@ferdinandy.com>
* docs: add :recover commandRobin Jarry2023-09-191-0/+11
| | | | | | | | This command was not documented. Make it so. Fixes: cdec23323c64 ("recover: recover emails from tempdir after a crash") Signed-off-by: Robin Jarry <robin@jarry.cc> Reviewed-by: Bence Ferdinandy <bence@ferdinandy.com>
* docs: add [ui].client-threads-delay settingRobin Jarry2023-09-191-0/+7
| | | | | | | | This setting was not documented. Make it so. Fixes: 54a0a377e030 ("threads: debounce client-side thread building") Signed-off-by: Robin Jarry <robin@jarry.cc> Reviewed-by: Bence Ferdinandy <bence@ferdinandy.com>
* msgviewer: add styles for part selectorRobin Jarry2023-09-191-0/+9
| | | | | | | | | Allow styling the part selector mime type and (if any) attachment filename. Remove custom alignment code since now both can be differentiated easily with colors and/or attributes. Signed-off-by: Robin Jarry <robin@jarry.cc> Tested-by: Inwit <inwit@sindominio.net>
* config: add default values for empty stylesetsRobin Jarry2023-09-191-0/+39
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | When adding new style objects it is impossible to give them a default color nor attributes without modifying each existing user styleset. Also, if the user has an incomplete styleset, some parts of aerc will have no style at all. These quirks are not nice from a user experience point of view. Before parsing the user styleset, initialize aerc style with basic defaults. Reuse the exact same content than the actual "default" styleset provided in /usr/share/aerc/stylesets. Comment all of the default styleset to make it obvious that these are default values. This has some implications: * To reset these defaults, the user styleset must now start with these two lines: *.default = true *.normal = true If these two lines are not present, the default style will be kept and only changed if the user styleset explicitly sets them. * Empty stylesets no longer produce weird results. Signed-off-by: Robin Jarry <robin@jarry.cc> Tested-by: Inwit <inwit@sindominio.net>
* config: make all message list symbols/icons configurableowl2023-09-191-1/+35
| | | | | | | | | | This patch removes the hard coded letters (which don't make sense in all languages), and replaces them with configurable icons, like the existing `icon-attachment` and other icons. Signed-off-by: owl <owl@u8.is> Acked-by: Robin Jarry <robin@jarry.cc> Reviewed-by: Bence Ferdinandy <bence@ferdinandy.com>
* binds: control and alt modifiers for deleteVitaly Ovchinnikov2023-09-191-0/+4
| | | | | | | | Add Control and Alt modifiers to Delete key, so C-Delete and A-Delete kebyoard shortcuts could be bound. Signed-off-by: Vitaly Ovchinnikov <v@postbox.nz> Acked-by: Robin Jarry <robin@jarry.cc>
* doc: mention correct function in the example for compactDirKirill Miazine2023-09-181-1/+1
| | | | | Signed-off-by: Kirill Miazine <km@krot.org> Acked-by: Moritz Poldrack <moritz@poldrack.dev>
* doc: MIME type consistency spellingKirill Miazine2023-09-181-1/+1
| | | | | | | | Refer to MIME type as "MIME type", as that's how it's being called elsewhere. Signed-off-by: Kirill Miazine <km@krot.org> Acked-by: Moritz Poldrack <moritz@poldrack.dev>
* compose: add option for LF-only editorsMoritz Poldrack2023-09-181-0/+7
| | | | | | | | | | | | Some editors only support LF line endings. For these, standard compliant eml files are not an option. Add an option compose.lf-editor to translate the eml file to lf lineendings. Signed-off-by: Moritz Poldrack <git@moritz.sh> Acked-by: Robin Jarry <robin@jarry.cc> Tested-by: Matěj Cepl <mcepl@cepl.eu>
* doc: clarify notmuch+maildir behavior with respect to filesinwit2023-09-041-3/+9
| | | | | | | | | | While notmuch mainly deals with messages and queries, adding either of *maildir-store* or *maidlir-account-path* will give the impression that aerc actually deals with files and folders under the notmuch interface. Clarify this point to avoid confusions. Signed-Off-By: inwit <inwit@sindominio.net> Acked-by: Robin Jarry <robin@jarry.cc>
* postpone: change recall/postpone logic for custom foldersVitaly Ovchinnikov2023-08-301-5/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change `:recall -f` behavior so it remembers the source folder the message is taken from and the further `:postpone` call can save it back to that folder. Change the `:recall` tab closing behavior, so it no longer asks if the recalled message needs to be deleted. This is now done automatically. Add an optional `-t <folder>` parameter to `:postpone`, so the message can be saved in a different folder. Change `:postpone` behavior, so it checks if the message was force-recalled from a different folder, and then it saves the message there. The "breaking" change is made to the closing handler of the recalled message tab. There was a confirmation dialog that asked if the recalled message needs to be deleted. This is now removed and replaced with a pretty simple logic: if the recalled message is either sent or re-postponed - it is safe to delete the original. Otherwise (if the recalled message editing is discarded, any other reasons?) the message is left intact, there is no need to ask for deleting it. If the user don't need that message - they can delete it manually. Another "breaking" change to the same handler is that it always works this way regardless of the curently selected folder. There was an `if` that checked that, but as the recalled messages are now only deleted if they are re-sent or re-postponed, it seems that there is no need to check the current folder anymore. Signed-off-by: Vitaly Ovchinnikov <v@postbox.nz> Acked-by: Robin Jarry <robin@jarry.cc>
* compose: use email domain name in Message-IdAdnan Maolood2023-08-281-0/+6
| | | | | | | | | | | | | RFC 5322 recommends using a domain name on the right-hand side of the "@" in Message-Ids. Since the local host domain name cannot be obtained reliably, use the sender email domain name by default. Add a new configuration option to maintain the old behavior. Link: https://www.rfc-editor.org/rfc/rfc5322.html#section-3.6.4 Signed-off-by: Adnan Maolood <adnan@maolood.com> Acked-by: Robin Jarry <robin@jarry.cc>
* commands: allow reading attachments from a fileKarel Balej2023-08-241-4/+8
| | | | | | | | | | | | | | | | | | | | | | | | Currently, aerc reads a list of files to be attached to a message from the file-picker-cmd's standard output. However, this doesn't play nice with ranger which seems to draw itself by writing there, causing it to be invisible in the embedded terminal. In fact, instead of using a pipe, aerc redirects the output of the command to a temporary file and then reads the list of files from there. Take advantage of this approach and allow user to directly reference this temporary file in the file-picker-cmd via the %f placeholder, which gets expanded to the temporary file's location. If the %f placeholder isn't present, keep the old behaviour. So for example, now it is possible to do: file-picker-cmd=ranger --choosefiles=%f in aerc.conf. Signed-off-by: Karel Balej <balejk@matfyz.cz> Acked-by: Robin Jarry <robin@jarry.cc> Reviewed-by: Tim Culverhouse <tim@timculverhouse.com>
* doc: add MessageId to aerc-templates.7Tim Culverhouse2023-08-241-0/+6
| | | | | | | | | | {{.MessageId}} is available within templates but undocumented. Previously, users could have surmised a way to get the message ID using {{.Header "message-id"}}, but since this is built into the struct already, document it for ease of use. Signed-off-by: Tim Culverhouse <tim@timculverhouse.com> Acked-by: Moritz Poldrack <moritz@poldrack.dev>
* doc: add <esc> to aerc-binds.5Keenan Gugeler2023-08-241-0/+2
| | | | | | | We always accepted this binding, but it was never documented. Signed-off-by: Keenan Gugeler <me@kgugeler.ca> Acked-by: Moritz Poldrack <moritz@poldrack.dev>
* style: add msglist_gutter and msglist_pill to configKonstantin Shelekhin2023-08-111-0/+4
| | | | | | | | | | Allow a user to change the default style of the message list scrollbar. There is no easy way to set the default style for an object directly in code, so I've updated every built-in theme to preserve the existing style. Signed-off-by: Konstantin Shelekhin <k.shelekhin@ftml.net> Acked-by: Robin Jarry <robin@jarry.cc>
* doc: strip email addresses in authors sectionRobin Jarry2023-08-1115-45/+45
| | | | | | | | Let's not encourage users to send us personal emails. The referenced URL https://sr.ht/~rjarry/aerc/ should have all necessary information. Signed-off-by: Robin Jarry <robin@jarry.cc> Acked-by: Moritz Poldrack <moritz@poldrack.dev>
* notmuch: add option to provide path for accountKirill Chibisov2023-08-051-0/+6
| | | | | | | | | | Add the "maildir-account-path" account configuration option to select the account relative to the "maildir-store" to have traditional maildir one tab per account behavior with notmuch. Signed-off-by: Kirill Chibisov <contact@kchibisov.com> Acked-by: Robin Jarry <robin@jarry.cc> Tested-by: Bence Ferdinandy <bence@ferdinandy.com>
* export-mbox: only export marked messages, if anyVitaly Ovchinnikov2023-08-051-1/+3
| | | | | | | | | | Change the `:export-mbox` behavior, so if some messages are marked with `:mark` - only those messages are exported. If nothing is marked - the whole folder is exported, as usual. Signed-off-by: Vitaly Ovchinnikov <v@postbox.nz> Acked-by: Robin Jarry <robin@jarry.cc> Tested-by: Koni Marti <koni.marti@gmail.com>
* attach: add an option to pipe the attachments inVitaly Ovchinnikov2023-08-051-0/+5
| | | | | | | | | | | | | | | Add the -r option to :attach so that the attachments can be piped in from a command. Example: :attach -r image.jpg read-jpeg-from-clipboard.sh It takes two parameters: the attachment name (to be used in the email and to get the MIME type from) and the command to execute and read the output. Signed-off-by: Vitaly Ovchinnikov <v@postbox.nz> Acked-by: Robin Jarry <robin@jarry.cc> Reviewed-by: Koni Marti <koni.marti@gmail.com>