about summary refs log tree commit diff stats
Commit message (Collapse)AuthorAgeFilesLines
...
* notmuch: add internal event loopReto Brunner2020-02-163-12/+38
|
* notmuch: emit DirInfo upon requestReto Brunner2020-02-161-12/+44
|
* Request DirInfo whenever the unread count may have changedReto Brunner2020-02-162-0/+16
| | | | | | | Actions such as read / unread or the addition of new messages do change the read/unread/recent count. Hence we request an update from the workers. Workers going over the network should probably cache the information and invalidate it only if necessary
* dirlist: actually honor the DirInfoReto Brunner2020-02-162-25/+39
| | | | | | | | | | | | Currently the dirlist ignores the counts provided by the dirInfo. However some of the workers can actually provide accurate counts much quicker than if we count the flags. Eventually we will also want to enable displaying counts for background folders, where the brute force counting won't work as none of the headers are fetched yet. This commit models it in an opt-in manner, if the flag isn't set then we still count the messages manually.
* Only fetch the directory contents when we are switching directoriesReto Brunner2020-02-163-9/+18
| | | | | | Previously, sending a DirectoryInfo assumed that a directory change happened. However we don't want that if we only want to update the unread message count.
* imap: fix double closing idleStopReto Brunner2020-02-161-2/+4
| | | | | | The idle restart code is at the end of handleMessage in the worker. However if an unsupported msg comes in, we returned early, skipping the re-init. That lead to a crash due to double closing idleStop in the next iteration.
* notmuch: avoid stale DBsReto Brunner2020-02-161-99/+133
| | | | | | | | | | | | | | Opening a notmuch DB gives you a snapshot of the stage at that specific time. Prior to this, we only reopened the DB upon writing. However, if say a mail sync program like offlineimap is fetching new mail, we would never pick it up. This commit caches a db for a while, so that we don't generate too much overhead and does a reconnect cycle after that. I hardcoded a value as I don't think that having an option would be beneficial. Any write operation (meaning reading mail) anyhow flushes the DB by necessity. (we need to close to commit tag changes, which changing the read state is)
* lib: fix an out of bounds panic in the serverDaniel Martí2020-02-131-1/+2
| | | | | | | | | | | | | | | | | If the message doesn't contain ':', we don't properly discard the message, so we end up slicing it like msg[:-1]. This can be reproduced if one runs 'aerc foo', as the server receives 'foo' as the message. 'aerc foo' still doesn't do anything very user friendly, but at least it doesn't panic horribly. While at it, do the 'got message' log at the very beginning, so that the user can see what message the server got before reporting the command as invalid. Signed-off-by: Daniel Martí <mvdan@mvdan.cc>
* Fix typo in message view sectionErazem Kokot2020-02-121-1/+1
|
* Ensure we aren't selecting negative directoriesAndreas Rammhold2020-02-071-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When the list of directories is empty trying to navigate in the directory list did previously lead to a crash. With this change we instead return early before trying to change the directory. Example backtrace: > panic: runtime error: index out of range [-1] > > goroutine 1 [running]: > git.sr.ht/~sircmpwn/aerc/widgets.(*DirectoryList).NextPrev(0xc000160680, 0xffffffffffffffff) > source/aerc/widgets/dirlist.go:285 +0xd4 > git.sr.ht/~sircmpwn/aerc/commands/account.NextPrevFolder.Execute(0xc000191040, 0xc00025c210, 0x1, 0x1, 0x0, 0xc00016f420) > source/aerc/commands/account/next-folder.go:44 +0xe0 > git.sr.ht/~sircmpwn/aerc/commands.(*Commands).ExecuteCommand(0xc0000101a8, 0xc000191040, 0xc00025c210, 0x1, 0x1, 0xc000020070, 0xb46d01) > source/aerc/commands/commands.go:66 +0xa7 > main.execCommand(0xc000191040, 0xc0001ca190, 0xc00025c210, 0x1, 0x1, 0xc00025c210, 0xc0003fb080) > source/aerc/aerc.go:60 +0xc7 > main.main.func3(0xc00025c210, 0x1, 0x1, 0x1, 0x1) > source/aerc/aerc.go:162 +0x57 > git.sr.ht/~sircmpwn/aerc/widgets.(*Aerc).BeginExCommand.func1(0xc000201db0, 0xb) > source/aerc/widgets/aerc.go:382 +0x83 > git.sr.ht/~sircmpwn/aerc/widgets.(*ExLine).Event(0xc0003be100, 0xb475a0, 0xc00023cba0, 0xc00023cba0) > source/aerc/widgets/exline.go:79 +0x131 > git.sr.ht/~sircmpwn/aerc/widgets.(*Aerc).Event(0xc000191040, 0xb475a0, 0xc00023cba0, 0x99ee01) > source/aerc/widgets/aerc.go:202 +0x4c1 > git.sr.ht/~sircmpwn/aerc/widgets.(*Aerc).simulate(0xc000191040, 0xc000036f00, 0xd, 0x10) > source/aerc/widgets/aerc.go:195 +0x8d > git.sr.ht/~sircmpwn/aerc/widgets.(*Aerc).Event(0xc000191040, 0xb475a0, 0xc00023c9c0, 0x9c5a60) > source/aerc/widgets/aerc.go:218 +0x3e8 > git.sr.ht/~sircmpwn/aerc/lib/ui.(*UI).Tick(0xc0001ca190, 0xa99d00) > source/aerc/lib/ui/ui.go:92 +0x190 > main.main() > source/aerc/aerc.go:192 +0x5f2
* worker/lib/parse: be more tolerant with parsing email addressesTimmy Douglas2020-02-061-1/+1
|
* Add link to scdocNoah Kleiner2020-02-021-1/+1
|
* dirlist: adapt to dynamic UIconfigReto Brunner2020-01-282-11/+21
|
* dirlist: remove not needed sort functionReto Brunner2020-01-281-2/+1
| | | | | | | | | | The docs of strings.Compare state: > Compare is included only for symmetry with package bytes. It is usually > clearer and always faster to use the built-in string comparison operators > ==, <, >, and so on. So let's do that.
* config: Strongly type context typeReto Brunner2020-01-243-7/+10
| | | | | | | | The go compiler can't help much with untyped int constants. Even though the only valid constants are 0-3 it will happily accept 4 as input. Let's let the go compiler worry about correctness here. This also allows people not very familiar with the code to use it properly via auto completion.
* imap: emit messageinfo when changing read state.Reto Brunner2020-01-241-2/+17
| | | | We need to emit the changed msgInfo whenever we modify the state
* Contextual UI ConfigurationSrivathsan Murali2020-01-247-20/+170
| | | | | | | | | + Adds parsing of contextual ui sections to aerc config. + Add GetUiConfig method for AercConfig that is used to get the specialized UI config. + Add UiConfig method to AccountView to get specialized UI Config. + Modifies Aerc codebase to use specialized UIConfig instead. + Adds documentation for Contextual UI Configuration
* Fix handling of multiple template-dirsBen Burwell2020-01-242-4/+6
| | | | | | | | Before, while the docs stated that template-dirs was a colon-separated list, a delimiter was not specified in the struct tag, so it was falling back to the default for the ini library (a comma). Also added a note to the docs to clarify that templates are configured in the [templates] section.
* msgview/open: remove manual decodingReto Brunner2020-01-201-11/+0
|
* msgview/save: Adapt to already decoded readerReto Brunner2020-01-202-74/+134
| | | | | | | | | | The functionality was broken since the decoding changes. This commit also simplifies the code (in my view) to make the application logic easier to follow. The docs are updated accordingly (the feature was poorly documented). As far as I am aware there should be no breaking changes (and is certainly still in the spec of the prior documentation)
* Display the mimetype when offering to pipe or saveLuke Drummond2020-01-201-1/+3
|
* worker/imap: don't decode in FetchFullMessage.Reto Brunner2020-01-181-27/+2
| | | | | Doing that breaks `git am` as it expected the encoded variant. Same is probably true for any sort of signature validation (gpg / dkim)
* Switch back to upstream pty libraryBen Fiedler2020-01-163-4/+4
| | | | | The relevant change was merged upstream, and thus allows us to clean up unneeded forks.
* Correct spellingReto Brunner2020-01-161-1/+1
|
* Add docs for reply -TBen Burwell2020-01-111-1/+3
|
* Strip trailing newline from address book entries without namesBen Burwell2020-01-091-9/+11
| | | | | | | When the list of completions from the external command doesn't have associated contact names, the email address we attempt to parse was being terminated with a newline. Now, we strip the trailing newline if present.
* compose: don't call ti.tabcomplete when it is nilTimmy Douglas2020-01-091-0/+4
|
* template: man cosmetic changesLeszek Cimała2020-01-091-1/+2
|
* template: add exec and wrapLeszek Cimała2020-01-092-4/+40
|
* template: remove last \n to fix additional new lines after quoteLeszek Cimała2020-01-091-0/+2
|
* add .OriginalMIMEType variable to reply templateLeszek Cimała2020-01-094-18/+39
|
* remove Original* checkLeszek Cimała2020-01-091-2/+1
|
* create OriginalMail structLeszek Cimała2020-01-098-24/+44
|
* maildir/notmuch: don't re-encode readersReto Brunner2020-01-051-37/+4
|
* imap: decode reader prior to returning themReto Brunner2020-01-051-10/+90
|
* FetchBodyParts: decode source in the workersReto Brunner2020-01-058-117/+29
| | | | | | | Previously the workers returned a mixture of decoded / encoded parts. This lead to a whole bunch of issues. This commit changes the msgviewer and the commands to assume parts to already be decoded
* models: add BodyStructure.PartAtIndexReto Brunner2020-01-051-0/+33
|
* msgviewer: decode headers prior to displaying themReto Brunner2020-01-051-1/+7
|
* msgviewer: bypass filter for headersReto Brunner2020-01-051-3/+6
|
* msgviewer: do not anchor ansi escape to start of lineReto Brunner2020-01-051-1/+1
|
* Reword aerc-tutorial with revised constraintsDrew DeVault2020-01-051-5/+5
| | | | | This document used to specify some constraints on the receipient address, but this has since been corrected in aerc.
* Don't select completions until tab has been pressedBen Burwell2020-01-051-6/+8
| | | | | | | | | | | | | | | Before, pressing <Enter> when completions were visible would execute the selected completion. As soon as completions were provided, the first item would be selected. This could cause issues e.g. when changing folders: :cf <Enter> Previously, this would have selected the first folder in the list. Now, since <Tab>, <C-n>, etc have not been pressed to select the first completion, the command above simply executes `:cf `. To accomplish this, a "no-op completion" has been added at index -1.
* Fix double >\n when quoting empty lineSrivathsan Murali2020-01-041-0/+1
|
* Handle MIME encoded addresses in address bookBen Burwell2019-12-301-2/+12
| | | | | | | | | | | When addresses contain special characters, net/mail MIME-encodes them to a valid RFC 5322 address for use in headers. However, these are not pleasant for human consumption, so we decode them for use in the completion list. Aerc properly encodes addresses when the message is sent. This patch also removes surrounding white space from contact names, if present.
* msgviewer: Add Labels as a virtual headerReto Brunner2019-12-272-6/+26
| | | | | | In order to accommodate for that, the headerlayout needed to be rewritten to pass the filter criteria back to the msgviewer, instead of just using the normal headers.
* Add labels to index format (%g)Reto Brunner2019-12-277-0/+22
| | | | Exposes the notmuch tags accordingly, stubs it for the maildir worker.
* Add missing man pages to uninstall target in MakefileAriel Popper2019-12-241-0/+2
|
* fix invalid format stringReto Brunner2019-12-221-1/+1
|
* read: adapt to ProvidesMessagesReto Brunner2019-12-222-21/+90
|
* modify-labels: add completionReto Brunner2019-12-212-1/+37
|