Commit graph

42 commits

Author SHA1 Message Date
Robin Jarry
bb9ac43e13 switch: add -n and -p flags for relative switch
Allow switching to next or previous account with switch-account -n and
switch-account -p, respectively. By default, these are bound to Alt-n
and Alt-p.

Signed-off-by: Robin Jarry <robin@jarry.cc>
Tested-by: Koni Marti <koni.marti@gmail.com>
2022-09-20 20:55:29 +02:00
Robin Jarry
e808b96d63 binds: allow typing ? in subject header
Since commit 5c8a749cfa ("binds: display active keybinds in a dialog
box") the ? key is bound to `:help keys` in the global section which
applies to all binding contexts. Pressing ? while editing any email
headers in the compose window (when the editor is not selected) displays
the active bindings menu.

Add $noinherit=true in the [compose] context to allow typing any
character. Copy the bindings for next-tab and prev-tab so that users can
still change tabs while editing headers.

Cc: Akspecs <akspecs@gmail.com>
Signed-off-by: Robin Jarry <robin@jarry.cc>
2022-09-20 00:03:28 +02:00
Koni Marti
5c8a749cfa binds: display active keybinds in a dialog box
Show contextual keybinds in a textbox when using the ':help keys'
command. This command is bound to '?' by default.

Fixes: https://todo.sr.ht/~rjarry/aerc/42
Signed-off-by: Koni Marti <koni.marti@gmail.com>
Acked-by: Robin Jarry <robin@jarry.cc>
2022-08-22 09:30:37 +02:00
Tim Culverhouse
be2abb3d91 binds: Open msgs in default Postpone folder in edit-mode
Add a default keybind to open messages in the default Postpone folder
("Drafts") in edit-mode.

A frequent question on IRC is "how do I edit a draft?". When a user
selects a Draft and presses <Enter>, the intent is usually to edit that
draft. This commit makes this the default behaviour for the default
Postpone folder.

Signed-off-by: Tim Culverhouse <tim@timculverhouse.com>
Acked-by: Robin Jarry <robin@jarry.cc>
2022-06-22 11:36:46 +02:00
Koni Marti
e1d8bc4d17 msgviewer: open http links from messages
Parse http links from a message and display them as completions in the
:open-link command.

Add the following binds to the [view] section in your binds.conf:
<C-l> = :open-link <space>

Parsing can be disabled in aerc.conf by setting parse-http-links to
false in the viewer section.

Thanks to Moritz for the help with the regular expression.

Signed-off-by: Koni Marti <koni.marti@gmail.com>
Reviewed-by: Moritz Poldrack <git@moritz.sh>
Acked-by: Robin Jarry <robin@jarry.cc>
2022-06-14 22:12:48 +02:00
kt programs
dc271b4da2 binds: add binding for :open by default in viewer
Also move binding for :delete such that the :open, :save, :pipe command
bindings are grouped together.

Signed-off-by: kt programs <ktprograms@gmail.com>
Acked-by: Robin Jarry <robin@jarry.cc>
2022-04-14 23:48:26 +02:00
kt programs
74366d895d viewer: add key passthrough mode
When trying to search in less, keys bound to viewer functions can't be
used as part of the search query, which makes the search useless.

Add a view::passthrough binding mode and a :toggle-key-passthrough
command go toggle in and out of that mode. By default, typing '/' in the
viewer is bound to enabling key passthrough and automatically inserting
'/', to easily enter "less" search mode. When in the passthrough mode,
all bindings are ignored by default. The default binds.conf only defines
a single keybinding in that mode: <Esc> to get back out. $ex is bound to
<C-x> to allow typing colons.

Signed-off-by: Kt Programs <ktprograms@gmail.com>
Acked-by: Robin Jarry <robin@jarry.cc>
2022-03-14 22:55:19 +01:00
Maxim Karasev
37477794b2 config: fix default PgUp/PgDn bindings
If -s is present, aerc just shows usage info.

Signed-off-by: Maxim Karasev <begs@disroot.org>
Acked-by: Inwit <inwit@sindominio.net>
2022-02-28 00:30:50 +01:00
Koni Marti
7811620eb8 threading: implement on-the-fly message threading
implement message threading on the message store level using the
jwz algorithm. Build threads on-the-fly when new message headers arrive.

Use the references header to create the threads and the in-reply-to
header as a fall-back option in case no references header is present.

Does not run when the worker provides its own threading (e.g. imap
server threads).

Include only those message headers that have been fetched and are
stored in the message store.

References: https://www.jwz.org/doc/threading.html
Signed-off-by: Koni Marti <koni.marti@gmail.com>
Tested-by: Inwit <inwit@sindominio.net>
Tested-by: akspecs <akspecs@gmail.com>
Acked-by: Robin Jarry <robin@jarry.cc>
2022-02-24 13:00:12 +01:00
Koni Marti
8f9a633523 commands: add expand-folder and collapse-folder
add the expand-folder and collapse-folder commands to navigate the
directory tree view. Provide keybinds for a vi-like folder navigation
experience.

Signed-off-by: Koni Marti <koni.marti@gmail.com>
2022-02-23 21:09:01 +01:00
Robin Jarry
923e949c05 binds.conf: change default review bindings
Add missing :detach binding.
Ask user for confirmation when pressing 'q'.

Signed-off-by: Robin Jarry <robin@jarry.cc>
2022-02-02 22:12:08 +01:00
Kalyan Sriram
88d28908d2 binds: add escape to clear search 2021-11-13 15:20:54 +01:00
Jeffas
7f033278eb Add postpone command
This command uses the Postpone folder from the account config to save
messages to. Messages are saved as though they were sent so have a valid
'to' recipient address and should be able to be read back in for later
editing.
2020-04-24 12:59:21 -04:00
Ray Ganardi
06bb332285 fix binding for delete message
I guess confirm command was removed sometime ago, but the config
template was not updated.
2020-04-20 10:52:09 -04:00
Reto Brunner
1ba9f0da19 binds.conf: mark bindings 2019-12-21 09:27:54 -05:00
Kevin Kuehler
f81e4bd41c Implement :filter, :clear
Signed-off-by: Kevin Kuehler <keur@ocf.berkeley.edu>
2019-07-19 11:30:32 -04:00
Drew DeVault
8b2abcb02a Change default attach keybinding 2019-07-19 10:45:44 -04:00
Drew DeVault
687f1d8c1a Update binds.conf 2019-07-04 09:58:31 -04:00
Drew DeVault
91a75cd98b Implement :search, :next-result, :prev-result 2019-06-26 20:50:54 -04:00
Drew DeVault
63538978f3 Fix reply bindings in [view] 2019-06-19 20:07:33 -04:00
Drew DeVault
0494c9ae9d Add :next/:prev binds for [viewer] 2019-06-11 09:36:18 -04:00
Yash Srivastav
702ad43bd2 Override $ex in compose view 2019-06-09 15:51:30 -04:00
Robert Günzler
acfe7d7625 Add archive command
Adds an archive command that moves the current message into the folder
specified in the account config entry.

Supports three layouts at this point:

- flat: puts all messages next to each other
- year: creates a folder per year
- month: same as above, plus folders per month

This also adds a "-p" argument to "cp" and "mv" that works like
"--parents" on mkdir(1). We use this to auto-create the directories
for the archive layout.
2019-06-09 11:33:50 -04:00
Drew DeVault
150a271b36 Add binding to toggle headers 2019-06-07 10:08:09 -04:00
Drew DeVault
0ec970bce8 Add delete to the default binds.conf 2019-06-02 15:43:32 -04:00
Galen Abell
28fc9fa53d Add :save and :pipe commands to viewer
* :save takes a path and saves the current message part to that location
* :pipe is the same as pipe on the account page, but uses the current
  message part rather than the whole email (ie :pipe gzip -d)
* Refactored account:pipe and extracted common pipe code to
  commands.util.QuickTerm
* Added helper command aerc.PushError
2019-05-27 09:37:07 -04:00
Drew DeVault
887ff6550d Implement :edit in compose screen 2019-05-26 11:58:14 -04:00
Drew DeVault
11a569f658 binds.conf: make reply -a easier to use than reply 2019-05-25 16:51:14 -04:00
Francis Dinh
10a3d9d209 Bind :compose to C in binds.conf
The tutorial mentions using "C" for composing messages, but this was not
actually implemented in binds.conf.
2019-05-23 18:01:24 -04:00
Drew DeVault
0897413a3e Implement :next-part, :prev-part 2019-05-20 16:49:39 -04:00
Drew DeVault
455c6f0b77 Rename :delete-message et al to :delete et al 2019-05-19 18:23:34 -04:00
Drew DeVault
08855f23ec Change default bindings for replies 2019-05-16 14:06:33 -04:00
Drew DeVault
e367469e1a Change default reply keybindings 2019-05-16 12:42:25 -04:00
Drew DeVault
52b318127f Fix default bindings for quit and edit 2019-05-14 19:18:33 -04:00
Drew DeVault
67ddaea1b2 Move ! bind to [messages] 2019-05-14 17:06:31 -04:00
Drew DeVault
6c0359670c Add (non-functional) reply commands to bindings 2019-05-14 17:04:21 -04:00
Drew DeVault
d3fe60a0fa Add ! to default keybindings 2019-05-14 16:57:10 -04:00
Drew DeVault
f77d7c2c3d Add distinct keybindings for each compose view 2019-05-14 14:27:28 -04:00
Drew DeVault
577248f5e1 Add initial compose widget 2019-05-12 00:06:09 -04:00
Drew DeVault
5d0402aeea Add message view commands, :close 2019-03-30 21:45:41 -04:00
Drew DeVault
04d9ab3ce6 Update default config/binds.conf 2019-03-30 21:40:41 -04:00
Drew DeVault
f5bf4a9324 Add context-specific keybindings 2019-03-21 17:37:19 -04:00