aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2019-09-11Fix segfault on deleteDevon Johnson
2019-09-11Add new search behaviour for imapJeffas
This patch adds search behaviour to allow searching in the body of the messages, the entire text (body + header), and searching just the from header.
2019-09-11Check the subject line for lowercase reJeffas
This ensures that a message with e.g. "RE: " at the start won't get another "Re: ".
2019-09-11Ensure mimetype parts are converted to lower caseJeffas
This ensures that the check for a text message to use in the reply is performed (more) correctly and so uses the plaintext more often.
2019-09-11Add MouseableJeffas
This adds the Mouseable interface. When this is implemented for a component that item can accept and process mouseevents. At the top level when a mouse event is received it is passed to the grid's handler and then it trickles down until it reaches a component that can actually handle it, such as the tablist, dirlist or msglist. A mouse event is passed so that components can handle other things such as scrolling with the mousewheel. The components themselves then perform the necessary actions. Clicking emails in the messagelist opens them in a new tab. Textinputs can be clicked to position the cursor inside them. Mouseevents are not forwarded to the terminal at the moment. Elements which do not handle mouse events are not required to implement the Mouseable interface.
2019-09-11Add initial command to end of completionsJeffas
This means that if the user cycles through all completions then they will see the initial string they entered.
2019-09-04widgets: gofmtWagner Riffel
Signed-off-by: Wagner Riffel <wgrriffel@gmail.com>
2019-09-04widgets: rewrite references to os.SET_SEEK to io.SeekStartWagner Riffel
Os.SET_SEEK is deprecated, it's recommended to use contants from io package Signed-off-by: Wagner Riffel <wgrriffel@gmail.com>
2019-09-04widgets: remove redundant key check, delete is no-op if key is emptyWagner Riffel
Signed-off-by: Wagner Riffel <wgrriffel@gmail.com>
2019-09-04commands: move ParseNextPrevMessage error value to its last return valueWagner Riffel
Signed-off-by: Wagner Riffel <wgrriffel@gmail.com>
2019-09-04all: rewrite references to strings.Index to strings.ContainsWagner Riffel
Signed-off-by: Wagner Riffel <wgrriffel@gmail.com>
2019-09-04all: use fmt.Errorf for fomartting errorsWagner Riffel
Signed-off-by: Wagner Riffel <wgrriffel@gmail.com>
2019-09-04all: purge redundant underscoresWagner Riffel
Signed-off-by: Wagner Riffel <wgrriffel@gmail.com>
2019-09-04aerc.go: simplify completionsDrew DeVault
2019-09-04aerc.go: remove unused variableDrew DeVault
2019-09-02Use sort.Stable for sorting displayed messagesa3v
With sort.Sort, sometimes two messages with the same timestamp will switch places every time the message list is redrawn
2019-08-30Allow custom spinner via config filePaul Spooren
Allows to set `ui.spinner=` to a string which is then split by `ui.spinner-delimiter=` (Default: comma) instead of having a hard coded animation. This implementation doesn't use INIs capabilities to split strings as it trims whitespaces breaking the default animation. Signed-off-by: Paul Spooren <mail@aparcar.org>
2019-08-29notmuch: add search / filter capabilitiesReto Brunner
2019-08-29extract search criteria parsing into the backendsReto Brunner
2019-08-29Fix out-of-order messages by sorting as we displayStephen Brennan
Sometimes I observe out-of-order messages when using a maildir inbox. It appears that the UIDs for these messages are returned out of order by the MessageStore. In order for a maildir MessageStore to return messages in most recently received order, it must have already opened all messages and parsed the date to use as a sort key. Rather than implement that, simply sort messages by time as we display. This fix shows my emails in order.
2019-08-26Notmuch: use adhoc write connection.Reto Brunner
Notmuch only allows a single write connection, all other clients trying to modify the db block. Hence we should only open one when we actually need it. Apparently we also need to refresh the RO DB connection upon modification, else we get stale message tag results
2019-08-26imap worker: do not copy mailbox status mutexWagner Riffel
Signed-off-by: Wagner Riffel <wgrriffel@gmail.com>
2019-08-26Add :prompt commandChristopher Vittal
Usage: :prompt <prompt> <command...> Displays the prompt on the status bar, waits for user input, then appends that input as the last argument to the command and executes it. The input is passed as one argument to the command, unless it is empty, in which case no extra argument is added.
2019-08-20Strip carriage returns (^M) when filtering emailsDaniel Xu
Presumably some email servers will transform newlines into carriage return new lines to better support windows users. I can't prove this but that's the best explanation I have for my hosted email provider (fastmail). Without this patch, I was seeing annoying `^M`s at the end of every filtered line. Signed-off-by: Daniel Xu <dxu@dxuuu.xyz>
2019-08-20Only compile regex portion of folder filterDaniel Xu
The code was trying to compile the `~` as well. In this case, it was trying to match a literal `~` to the front of the supplied regex. Fixes: 334ca89bea381 ("folder filter: only assume regex if filter is ~fmt") Signed-off-by: Daniel Xu <dxu@dxuuu.xyz>
2019-08-20folder filter: only assume regex if filter is ~fmtDrew DeVault
2019-08-20Add forwarding as attachment featureJelle Besseling
This allows a single message to be forward as attachment with the :forward -a command
2019-08-20Add addresses argument to forward commandJelle Besseling
2019-08-20Move forward command to it's own fileJelle Besseling
The two commands did not have much code in common
2019-08-20upgrade go-messageReto Brunner
Fixes date parsing bug in the maildir / notmuch workers.
2019-08-19Add support for <C-j> as '<Enter>' in ExLineChristopher Vittal
2019-08-19Support regex filters for foldersDaniel Xu
It's nice to be able to filter the folders displayed in the side bar. Basic string matching can get verbose with enough folders whitelisted. Signed-off-by: Daniel Xu <dxu@dxuuu.xyz>
2019-08-16bump go-message, fixes address list parsing failureReto Brunner
2019-08-13Revert "add close command at global level"Drew DeVault
This reverts commit f0a0c5aa733fa66958c113465bfc5fdd3d7cc9f0.
2019-08-13add close command at global levelAditya Srivastava
2019-08-13Add optional body argument to compose commandDaniel Bridges
2019-08-12Prevent drawing terminal with nil cmdDrew DeVault
2019-08-12Add delete forward <C-k> and backward <C-u>Christopher Vittal
Choose the readline defaults for the behavior of these two functions/keybindings. Depending on the program, either of these can delete the whole line. Note that by default in [compose], <C-k> is bound to :prev-field<Enter>. Leave it up to the user whether or not they want to rebind the key in [compose].
2019-08-12Joining the args in cf for folders with spacesBen Cohen
2019-08-12Pass os stdin to credential commandJonas Mueller
This is neccessary for `gpg-agent` to display a prompt and get the key to unlock a given password. See https://todo.sr.ht/~sircmpwn/aerc2/250.
2019-08-12Ignore scroll command when msgstore is nilJelle Besseling
Fixes ~sircmpwn/aerc2#205. Many functions do a nil check on the store, so this changes Store() so it returns nil when msglist is nil. It also places the Scroll() behind the nil check in the next-message command. https://todo.sr.ht/~sircmpwn/aerc2/205
2019-08-12Let user edit arbitrary headers in composerDaniel Bridges
2019-08-08maildir: Preserve flags when copying messagesBen Burwell
2019-08-08Close backends prior to shutdownReto Brunner
We need some way to signal the backends that we are about to shutdown, allowing them to clean up (for example in notmuch committing the db changes). This commit implements a hook which gets called upon shutdown, providing backends implement the io.Closer interface.
2019-08-08Fix `unread` commandArt Wild
This fixes ~sircmpwn/aerc2#195. While `read -t` works fine. The `unread` command is not wired. This patch fixes it. https://todo.sr.ht/~sircmpwn/aerc2/195
2019-08-08Add notmuch docsReto Brunner
2019-08-08Add notmuch backendReto Brunner
This commit introduces the notmuch backend. The backend is conditionally compiled in if the "notmuch" tag is provided. Most of the message types are implemented, with the notable exceptions of DeleteMessages as well as any copy / move / append type. Reason being, that those aren't normally applicable in a notmuch based workflow. Changes v2 --> v3, based on review comments * Use account config for configuration
2019-08-08add github.com/zenhack/go.notmuchReto Brunner
2019-08-08Extract message parsing to common worker moduleReto Brunner
Things like FetchEntityPartReader etc can be reused by most workers working with raw email files from disk (or any reader for that matter). This patch extract that common functionality in a separate package.
2019-08-08Don't print imap errors to uiJelle Besseling
This fixes ~sircmpwn/aerc2#245. This sets up the imap client to send error messages to the logger of the worker. Errors now end up in the bottom status line. https://todo.sr.ht/~sircmpwn/aerc2/245