~sircmpwn/aerc

7 3

introduce the "trash" command

Details
Message ID
<CE0251UC62PM.BA8TTZ77XVEC@clrinfopc42>
DKIM signature
fail
Download raw message
DKIM signature: fail
hi there,

in my aerc tree, I have introduced a new command: :trash.
it's somewhat similar to the :delete one, except it moves the (list of)
email(s) under the [Trash] folder.

I initially wrote a binding to do this but I didn't find a way to make
it behave the same than the :delete command (where it moves to the next
message afterwards).

would there be interest in providing it to aerc proper?

cheers,
-s
Details
Message ID
<CE027CQC70MR.36SX3Y5E31VR6@eiger>
In-Reply-To
<CE0251UC62PM.BA8TTZ77XVEC@clrinfopc42> (view parent)
DKIM signature
fail
Download raw message
DKIM signature: fail
On Fri Sep 3, 2021 at 7:05 AM UTC, Sebastien Binet wrote:
> in my aerc tree, I have introduced a new command: :trash.
> it's somewhat similar to the :delete one, except it moves the (list of)
> email(s) under the [Trash] folder.

This sounds to me like :archive
Details
Message ID
<CE02DELCJ82Q.APRG11FW8B6H@PC-DEV-TP2-21>
In-Reply-To
<CE0251UC62PM.BA8TTZ77XVEC@clrinfopc42> (view parent)
DKIM signature
pass
Download raw message
> in my aerc tree, I have introduced a new command: :trash.
> it's somewhat similar to the :delete one, except it moves the (list of)
> email(s) under the [Trash] folder.
sooo... something like :move Trash ?

> I initially wrote a binding to do this but I didn't find a way to make
> it behave the same than the :delete command (where it moves to the next
> message afterwards).
:move Trash selects the next message afterwards

> would there be interest in providing it to aerc proper?
If it's behaviour is different from :move Trash, this might be a good
idea. But it is hard to tell without knowing the exact behaviour of your
:trash command.
Details
Message ID
<CE02JUDEM16W.5CTPP5ZCT95H@clrinfopc42>
In-Reply-To
<CE027CQC70MR.36SX3Y5E31VR6@eiger> (view parent)
DKIM signature
fail
Download raw message
DKIM signature: fail
On Fri Sep 3, 2021 at 09:08 CET, Eyal Sawady wrote:
> On Fri Sep 3, 2021 at 7:05 AM UTC, Sebastien Binet wrote:
> > in my aerc tree, I have introduced a new command: :trash.
> > it's somewhat similar to the :delete one, except it moves the (list of)
> > email(s) under the [Trash] folder.
>
> This sounds to me like :archive

not exactly.
:trash is for messages I don't think I will need but "well, better stash
them in the [Trash] folder just in case, although it's ok if the garbage
collector gets rid of them at some point".

well, it's a bit like ":archive flat", but not quite.

-s
Details
Message ID
<CE02PD7DPGM3.1P2VJ4A7QGPUP@eiger>
In-Reply-To
<CE02JUDEM16W.5CTPP5ZCT95H@clrinfopc42> (view parent)
DKIM signature
fail
Download raw message
DKIM signature: fail
On Fri Sep 3, 2021 at 7:24 AM UTC, Sebastien Binet wrote:
> :trash is for messages I don't think I will need but "well, better stash
> them in the [Trash] folder just in case, although it's ok if the garbage
> collector gets rid of them at some point".

You can configure :archive to stick things in the [Trash] folder, using
`archive` in accounts.conf. It might make sense to be able to configure
multiple archive directories, but I don't think we need a separate
command for this.
Details
Message ID
<CE02PCIF4UKA.64058LQVMDCA@clrinfopc42>
In-Reply-To
<CE02DELCJ82Q.APRG11FW8B6H@PC-DEV-TP2-21> (view parent)
DKIM signature
fail
Download raw message
DKIM signature: fail
On Fri Sep 3, 2021 at 09:15 CET, Moritz Poldrack wrote:
> > in my aerc tree, I have introduced a new command: :trash.
> > it's somewhat similar to the :delete one, except it moves the (list of)
> > email(s) under the [Trash] folder.
> sooo... something like :move Trash ?
>
> > I initially wrote a binding to do this but I didn't find a way to make
> > it behave the same than the :delete command (where it moves to the next
> > message afterwards).
> :move Trash selects the next message afterwards

not when viewing the message.
when in the "message viewer" mode, displaying a given message, 
':move Trash' will dutifully move that message to [Trash] but will go
back to the main window.
with :delete, you're still in "message viewer" mode, but you're now
looking at the next message. (or you're back at the main window if there
are no more messages to crawl through.)

>
> > would there be interest in providing it to aerc proper?
> If it's behaviour is different from :move Trash, this might be a good
> idea. But it is hard to tell without knowing the exact behaviour of your
> :trash command.

let me send a patchset and show the code.

-s
Details
Message ID
<CE02Q94C6DV3.PYVTMIPDMXYK@PC-DEV-TP2-21>
In-Reply-To
<CE02PD7DPGM3.1P2VJ4A7QGPUP@eiger> (view parent)
DKIM signature
pass
Download raw message
Right now - at least to me - it sounds like changing the default
behaviour of :move inside the message view would be the easiest
solution, but I'd prefer to see the patch first.

> You can configure :archive to stick things in the [Trash] folder, using
> `archive` in accounts.conf. It might make sense to be able to configure
> multiple archive directories, but I don't think we need a separate
> command for this.
I agree that a new command might not be needed, the functionality itself
is useful though, and one should not have to "repurpose" :archive (what
if they actually want to archive mails? :D). Supporting multiple
archives might be a larger change.
Details
Message ID
<CE02Z07VNDFQ.235W8ZFTHYRSI@clrinfopc42>
In-Reply-To
<CE02Q94C6DV3.PYVTMIPDMXYK@PC-DEV-TP2-21> (view parent)
DKIM signature
fail
Download raw message
DKIM signature: fail
On Fri Sep 3, 2021 at 09:32 CET, Moritz Poldrack wrote:
> Right now - at least to me - it sounds like changing the default
> behaviour of :move inside the message view would be the easiest
> solution, but I'd prefer to see the patch first.

sent.
another avenue could be to add an option to :delete.
(but it was easier for me to just copy-paste the code of :delete and
rebrand it as :trash with the expected behaviour)

>
> > You can configure :archive to stick things in the [Trash] folder, using
> > `archive` in accounts.conf. It might make sense to be able to configure
> > multiple archive directories, but I don't think we need a separate
> > command for this.
> I agree that a new command might not be needed, the functionality itself
> is useful though, and one should not have to "repurpose" :archive (what
> if they actually want to archive mails? :D). Supporting multiple
> archives might be a larger change.

yeah, I do use archive for archiving my (interesting) emails back to 2001 :)

-s
Reply to thread Export thread (mbox)