#214 :next-result doesn't move relative to the cursor 3 months ago

on ~sircmpwn/aerc2


#214 :next-result doesn't move relative to the cursor 3 months ago

Comment by ~ake on ~sircmpwn/aerc2

Yup, I'm doing roughly the following:

git pull --rebase
make clean
:search test

#214 :next-result doesn't move relative to the cursor 3 months ago

Comment by ~ake on ~sircmpwn/aerc2

Interesting. I definitely have that commit, but the issue is still there for me. Is this working for you?

#214 :next-result doesn't move relative to the cursor 3 months ago

Comment by ~ake on ~sircmpwn/aerc2

~sircmpwn Is the fix for this not in master yet? I've just pulled master to check and it doesn't seem fixed to me

#214 :next-result doesn't move relative to the cursor 4 months ago

Ticket created by ~ake on ~sircmpwn/aerc2

If I search for an email, move the cursor up a few emails and then use :next-result the email selected is the second result instead of the first.

My expectation is that it would move to the next result relative to my cursor rather than relative to the last selected match.

#210 macOS: Unable to map ctrl keys 4 months ago

Comment by ~ake on ~sircmpwn/aerc2

Can you use ctrl + u or ctrl + d to move up and down in the message list?

I thought I had a similar issue at one point until I realised I had some bindings in tmux that overrode the bindings in aerc. Maybe you have a similar issue?

#127 panic: runtime error: index out of range in handleFetchMessages 4 months ago

Comment by ~ake on ~sircmpwn/aerc2

Applying this patch stops the issue for me:

diff --git lib/msgstore.go lib/msgstore.go
index a81f9ad..8855859 100644
--- lib/msgstore.go
+++ lib/msgstore.go
@@ -131,6 +131,10 @@ func (store *MessageStore) Update(msg types.WorkerMessage) {
                store.DirInfo = *msg
                if store.DirInfo.Exists != len(store.Uids) {
                        store.worker.PostAction(&types.FetchDirectoryContents{}, nil)
+               } else {
+                       // Todo: Fetch from cache, I presume that's what's neeed
+                       store.worker.Logger.Printf("Should fetch from cache here")
+                       store.worker.PostAction(&types.FetchDirectoryContents{}, nil)
                update = true
        case *types.DirectoryContents:

I think there might be some code missing to fetch the messages from a cache somewhere.

#166 Disembodied emails when composed via vim on macOS 4 months ago

Comment by ~ake on ~sircmpwn/aerc2

I can confirm that adding the above line fixed the issue for me too.

Maybe this ticket can be solved by adding a note to the documentation?

#159 Connection timeout 4 months ago

Comment by ~ake on ~sircmpwn/aerc2

~oren, you're right that config is no longer working for some reason. Here's what's working for me now: https://paste.sr.ht/~ake/08b2644241f33345e0713e70df8113f47c3febac

The key differences were using smtp+plain instead of smtps+plain, adding :587 as the port and adding the line smtp-starttls = yes.

#182 :next-folder n only moves one folder 5 months ago

Comment by ~ake on ~sircmpwn/aerc2

A simple fix for this is to expose dirlist.nextPrev and use that instead:

diff --git a/commands/account/next-folder.go b/commands/account/next-folder.go
index 6ad3d54..e1c9152 100644
--- a/commands/account/next-folder.go
+++ b/commands/account/next-folder.go
@@ -35,12 +35,10 @@ func NextPrevFolder(aerc *widgets.Aerc, args []string) error {
        if acct == nil {
                return errors.New("No account selected")
-       for ; n > 0; n-- {
-               if args[0] == "prev-folder" {
-                       acct.Directories().Prev()
-               } else {
-                       acct.Directories().Next()
-               }
+       if args[0] == "prev-folder" {
+               acct.Directories().NextPrev(-n)
+       } else {
+               acct.Directories().NextPrev(n)
        return nil
diff --git a/widgets/dirlist.go b/widgets/dirlist.go
index 1240e56..f40c796 100644
--- a/widgets/dirlist.go
+++ b/widgets/dirlist.go
@@ -122,7 +122,7 @@ func (dirlist *DirectoryList) Draw(ctx *ui.Context) {

-func (dirlist *DirectoryList) nextPrev(delta int) {
+func (dirlist *DirectoryList) NextPrev(delta int) {
        for i, dir := range dirlist.dirs {
                if dir == dirlist.selected {
                        var j int
@@ -152,9 +152,9 @@ func (dirlist *DirectoryList) nextPrev(delta int) {

 func (dirlist *DirectoryList) Next() {
-       dirlist.nextPrev(1)
+       dirlist.NextPrev(1)

 func (dirlist *DirectoryList) Prev() {
-       dirlist.nextPrev(-1)
+       dirlist.NextPrev(-1)

But this makes dirlist.Next and dirlist.Prev obsolete and doesn't match msglist, but maybe that should change too?