Re: Subject that ends with UTF-8, 85 or A0 e.g.:

2022-08-03 Thread Kevin J. McCarthy

On Wed, Aug 03, 2022 at 02:37:00PM +0900, Kenichi Asai wrote:

Yes, and it solved the problem!!!  Thank you very much!

I haven't compiled mutt by myself for long, so I rewrote the homebrew
formula to use the patch and let homebrew recompile (mutt 2.2.3).


Thank you Kenichi and Dennis for confirming the patch fixed the problem. 
That is great news!


I need to look carefully at other uses of isspace() inside Mutt too.

My final fix may be slightly different from the patch, but I will get 
this fixed for 2.2.7.  That release is overdue, so I will try to get 
that out soon.


--
Kevin J. McCarthy
GPG Fingerprint: 8975 A9B3 3AA3 7910 385C  5308 ADEF 7684 8031 6BDA


signature.asc
Description: PGP signature


Re: Subject that ends with UTF-8, 85 or A0 e.g.:

2022-08-02 Thread Dennis Preiser
On Tue, Aug 02, 2022 at 08:55:53PM -0700, Kevin J. McCarthy wrote:
> -  while (ISSPACE (*buf))
> +  while (is_email_wsp (*buf))

I was also able to reproduce the issue (on macOS) and can also confirm
that with this patch, the issue no longer occurs.

Dennis


Re: Subject that ends with UTF-8, 85 or A0 e.g.:

2022-08-02 Thread Kenichi Asai
> Darn, that was my best guess.  After I sent the email, I even found some old
> bug reports that 0xa0 was considered "space" on MacOS (e.g.
> https://bugs.python.org/issue7072)
> 
> Still, perhaps there is something different about the way Mutt was built
> versus the quick compile.
> 
> Have you ever built Mutt yourself?  Would you be able to try, and try
> applying the attached patch to a recent release tarball?

Yes, and it solved the problem!!!  Thank you very much!

I haven't compiled mutt by myself for long, so I rewrote the homebrew
formula to use the patch and let homebrew recompile (mutt 2.2.3).

It's really great that I don't have to check Subject every time any
more to see if the last character is truncated.  Thank you Kevin and
all the others for considering and solving this problem.

Sincerely,

-- 
Kenichi Asai


Re: Subject that ends with UTF-8, 85 or A0 e.g.:

2022-08-02 Thread Kevin J. McCarthy

On Wed, Aug 03, 2022 at 12:21:09PM +0900, Kenichi Asai wrote:

asai@bigsur % cat test.c
#include 
#include 

int main ()
{
 printf("%d\n", isspace(0xa0));
 printf("%d\n", isspace(0x85));
 printf("%d\n", isspace(0x0a));

 return 0;
}

[...]

asai@bigsur % ./test
0
0
1
asai@bigsur %


Darn, that was my best guess.  After I sent the email, I even found some 
old bug reports that 0xa0 was considered "space" on MacOS 
(e.g. https://bugs.python.org/issue7072)


Still, perhaps there is something different about the way Mutt was built 
versus the quick compile.


Have you ever built Mutt yourself?  Would you be able to try, and try 
applying the attached patch to a recent release tarball?


--
Kevin J. McCarthy
GPG Fingerprint: 8975 A9B3 3AA3 7910 385C  5308 ADEF 7684 8031 6BDA
From c2457b789989353db176ca3f899e838d9c67c0c2 Mon Sep 17 00:00:00 2001
From: Kevin McCarthy 
Date: Tue, 2 Aug 2022 20:51:17 -0700
Subject: [PATCH] wip: testing rfcline reader fix.

---
 parse.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/parse.c b/parse.c
index 7ed1668f..95dea4bf 100644
--- a/parse.c
+++ b/parse.c
@@ -72,7 +72,7 @@ char *mutt_read_rfc822_line (FILE *f, char *line, size_t *linelen)
 if (*buf == '\n')
 {
   /* we did get a full line. remove trailing space */
-  while (ISSPACE (*buf))
+  while (is_email_wsp (*buf))
 	*buf-- = 0;	/* we cannot come beyond line's beginning because
 			 * it begins with a non-space */
 
-- 
2.35.1



signature.asc
Description: PGP signature


Re: Subject that ends with UTF-8, 85 or A0 e.g.:

2022-08-02 Thread Kenichi Asai
> Would you mind creating a script to use for $editor.  Something like:
> 
> - - - - myeditor.sh - - - -
>   #!/bin/bash
> 
>   cp $1 ~/before.txt
>   vim $1
>   cp $1 ~/after.txt
> - - - - end myeditor.sh - - -
> 
> set editor = "~/myeditor.sh"
> 
> Then, if you put 加 at the end of the subject while in Mutt.  I'd like to
> see what before.txt and after.txt look like after vim runs.  Please attach
> them so I can look at the raw bytes.

Attached.  They were identical, both containing 加.

> Also, if you have access to a compiler, would you mind compiling and running
> this quick program:

Here you go:

asai@bigsur % cat test.c
#include 
#include 

int main ()
{
  printf("%d\n", isspace(0xa0));
  printf("%d\n", isspace(0x85));
  printf("%d\n", isspace(0x0a));

  return 0;
}
asai@bigsur % gcc --version
Configured with: --prefix=/Applications/Xcode.app/Contents/Developer/usr 
--with-gxx-include-dir=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/4.2.1
Apple clang version 13.0.0 (clang-1300.0.29.3)
Target: arm64-apple-darwin20.6.0
Thread model: posix
InstalledDir: 
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin
asai@bigsur % gcc -o test test.c
asai@bigsur % ./test
0
0
1
asai@bigsur %

-- 
Kenichi Asai
From: Kenichi Asai 
To: a...@is.ocha.ac.jp
Cc: 
Bcc: 
Subject: 加
Reply-To: 


-- 
お茶大・理・情報   浅井 健一   a...@is.ocha.ac.jp
From: Kenichi Asai 
To: a...@is.ocha.ac.jp
Cc: 
Bcc: 
Subject: 加
Reply-To: 


-- 
お茶大・理・情報   浅井 健一   a...@is.ocha.ac.jp


Re: Subject that ends with UTF-8, 85 or A0 e.g.:

2022-08-02 Thread Kenichi Asai
> > I try to send this e-mail out in 7bit mode (with υ at the end of
> > Subject).
> 
> Why would you do that when the discussion seems to be about UTF-8
> glyphs ?  I'm curious.

I just thought that quoted printable did some work on the Subject
line, but I was wrong.

-- 
Kenichi Asai


Re: Subject that ends with UTF-8, 85 or A0 e.g.:

2022-08-02 Thread Kevin J. McCarthy

On Wed, Aug 03, 2022 at 09:53:42AM +0900, Kenichi Asai wrote:

* In the step:
  "- enter some e-mail address and a subject."
if instead, you put a 加 at the end of the subject here, before running vim,
does 加 show up in vim?


Yes.


If you then don't modify the subject while still in
vim, does it show up in Mutt?


No.  It becomes the replacement character.


Thank you for taking the time to answer all my questions.

The subject line you sent appears to be truncated by one byte.  This 
also occurred for the 加 emails earlier.


Would you mind creating a script to use for $editor.  Something like:

- - - - myeditor.sh - - - -
  #!/bin/bash

  cp $1 ~/before.txt
  vim $1
  cp $1 ~/after.txt
- - - - end myeditor.sh - - -

set editor = "~/myeditor.sh"

Then, if you put 加 at the end of the subject while in Mutt.  I'd like 
to see what before.txt and after.txt look like after vim runs.  Please 
attach them so I can look at the raw bytes.


Also, if you have access to a compiler, would you mind compiling and 
running this quick program:


- - - - test.c - - - -
#include 
#include 

int main ()
{
  printf("%d\n", isspace(0xa0));
  printf("%d\n", isspace(0x85));
  printf("%d\n", isspace(0x0a));

  return 0;
}
- - - - end test.c - - - -

% gcc -o test test.c
% ./test

Thank you again.

--
Kevin J. McCarthy
GPG Fingerprint: 8975 A9B3 3AA3 7910 385C  5308 ADEF 7684 8031 6BDA


signature.asc
Description: PGP signature


Re: Subject that ends with UTF-8, 85 or A0 : �

2022-08-02 Thread Kenichi Asai
> > This e-mail has υ at the end of Subject.  I will send it out.
> 
> Somehow, the previous e-mail did not contain the replacement character
> at the end of Subject.  I don't know why.  Because the e-mail was
> quoted perhaps?
> 
> [text/plain, quoted, utf-8, 1.3K]
> 
> Bastian's e-mail is 7bit (as is my original e-mail):
> 
> [text/plain, 7bit, us-ascii, 0.7K]
> 
> I try to send this e-mail out in 7bit mode (with υ at the end of
> Subject).

The replacement characters in my previous e-mails do not show up in
mutt's pager (while the one in Bastian's e-mail does; I don't know
why), but if I see those e-mails in gmail, the replacement characters
do appear to exist.

-- 
Kenichi Asai


Re: Subject that ends with UTF-8, 85 or A0 e.g.: �

2022-08-02 Thread Kenichi Asai
> This e-mail has υ at the end of Subject.  I will send it out.

Somehow, the previous e-mail did not contain the replacement character
at the end of Subject.  I don't know why.  Because the e-mail was
quoted perhaps?

[text/plain, quoted, utf-8, 1.3K]

Bastian's e-mail is 7bit (as is my original e-mail):

[text/plain, 7bit, us-ascii, 0.7K]

I try to send this e-mail out in 7bit mode (with υ at the end of
Subject).

> * Does the problem occur if you use a different editor?

Yes.  The same thing happens with:

set editor="emacs %s"

-- 
Kenichi Asai


Re: Subject that ends with UTF-8, 85 or A0 e.g.: �

2022-08-02 Thread Kenichi Asai
Thank you all for considering this issue.

> * After you finish the above steps, what happens if you edit the email again
> in vim?  Does the 加 show up at the end of the subject in vim the second time?

No.  In vim, the character becomes ?? (two question marks).

> * With your original steps, what does the email look like if you send directly
> after returning from vim?

The replacement character is sent as seen in Bastian's e-mail:

Date: Tue, 2 Aug 2022 12:39:06 +0200
From: Bastian 
To: mutt-users@mutt.org
Subject: Re: Subject that ends with UTF-8, 85 or A0 ��

(I am not quite sure why there are two replacement characters here
instead of one.)

> Would you mind sending me an email so I can take a look?

This e-mail has υ at the end of Subject.  I will send it out.

> * Does the problem occur if you use a different editor?

Let me come back to this later.  I need to send this e-mail out to try
a different editor.

> * In the step:
>   "- enter some e-mail address and a subject."
> if instead, you put a 加 at the end of the subject here, before running vim,
> does 加 show up in vim?

Yes.

> If you then don't modify the subject while still in
> vim, does it show up in Mutt?

No.  It becomes the replacement character.

-- 
Kenichi Asai


Re: Subject that ends with UTF-8, 85 or A0 e.g.: υ

2022-08-02 Thread Paul Gilmartin via Mutt-users

On 8/2/22 13:58:37, Kevin J. McCarthy wrote:

On Tue, Aug 02, 2022 at 03:52:51PM +0900, Kenichi Asai wrote:

When the subject ends with a character whose last byte in
UTF-8 is either 85 or A0, it appears the character collapses. >
I'm having trouble duplicating this problem on Debian Testing.  So I'll 
need help debugging, from you or anyone else who can duplicate the problem.



Send it to the list, as I am doing with Thunderbird.
The more eyeball the better.

See: <https://datatracker.ietf.org/doc/html/rfc6532#section-3.2>.

--
gil


Re: Subject that ends with UTF-8, 85 or A0

2022-08-02 Thread Kevin J. McCarthy

On Tue, Aug 02, 2022 at 03:52:51PM +0900, Kenichi Asai wrote:

When the subject ends with a character whose last byte in
UTF-8 is either 85 or A0, it appears the character collapses.
To reproduce:

- prepare .mutt/muttrc containing only the following line:
 set edit_headers=yes
- launch mutt and type m to create a new mail.
- enter some e-mail address and a subject.
- vim launches.
- edit Subject line so that it ends with a character such as:
 υ or % or e (whose last byte of their UTF-8 code is 85) or
 ム or 加 (whose last byte of their UTF-8 code is A0).
- type :wq to quit vim.
- the last character is converted to something else.


Hi Kenichi,

I'm having trouble duplicating this problem on Debian Testing.  So I'll 
need help debugging, from you or anyone else who can duplicate the 
problem.


* After you finish the above steps, what happens if you edit the email 
again in vim?  Does the 加 show up at the end of the subject in vim the 
second time?


* With your original steps, what does the email look like if you send 
directly after returning from vim?  Would you mind sending me an email 
so I can take a look?


* Does the problem occur if you use a different editor?

* In the step:
  "- enter some e-mail address and a subject."
if instead, you put a 加 at the end of the subject here, before running 
vim, does 加 show up in vim?  If you then don't modify the subject while 
still in vim, does it show up in Mutt?


--
Kevin J. McCarthy
GPG Fingerprint: 8975 A9B3 3AA3 7910 385C  5308 ADEF 7684 8031 6BDA


signature.asc
Description: PGP signature


Re: Subject that ends with UTF-8, 85 or A0 �

2022-08-02 Thread Dennis Preiser
On Tue, Aug 02, 2022 at 11:17:14PM +0700, Đoàn Trần Công Danh wrote:
> On 2022-08-02 13:07:42+0200, Dennis Preiser  wrote:
>> On Tue, Aug 02, 2022 at 12:39:06PM +0200, Bastian wrote:
>> > Maybe some local vim/encoding issues on darwin?
>> 
>> Maybe. Interestingly, if I change the subject via 's' before sending in
>> mutt and replace the two replacement characters with 0x52a0 it works.
> 
> I noticed that your email was send with Content-type's charset is
> us-ascii and Kenichi's email is iso-2022-jp.
> 
> Is it part of the problem? I.e. Editors think the text files is
> an us-ascii or iso-2022-jp encoded file, and convert non-interpretable
> characters to utf-8 replacement?

I don't think so. If the editor thinks the file is us-ascii, then it
must not insert a UTF-8 replacement character.

Furthermore, this only happens if the character in question is at the
end of the subject. If it is at the beginning or somewhere in the middle
of the subject everything is fine. In other words, if the subject
consists of two 0x52a0 (Subject: 加加), the first one remains intact and
the second one is replaced by the UTF-8 replacement character.

Dennis


Re: Subject that ends with UTF-8, 85 or A0 加

2022-08-02 Thread Đoàn Trần Công Danh
On 2022-08-02 13:07:42+0200, Dennis Preiser  wrote:
> On Tue, Aug 02, 2022 at 12:39:06PM +0200, Bastian wrote:
> > I see it in the subject now.
> > There are two U+FFFD chars.
> > 
> >> | System: Darwin 21.6.0 (arm64)
> >> | ncurses: ncurses 6.3.20220625 (compiled with 6.3)
> >> | libiconv: 1.16
> >> | hcache backend: lmdb LMDB 0.9.70: (December 19, 2015)
> >> | 
> >> | Compiler:
> >> | Apple clang version 13.1.6 (clang-1316.0.21.2.5)
> >> | Target: arm64-apple-darwin21.5.0
> >> | Thread model: posix
> >> | [...]
> > 
> > Maybe some local vim/encoding issues on darwin?
> 
> Maybe. Interestingly, if I change the subject via 's' before sending in
> mutt and replace the two replacement characters with 0x52a0 it works.

I noticed that your email was send with Content-type's charset is
us-ascii and Kenichi's email is iso-2022-jp.

Is it part of the problem? I.e. Editors think the text files is
an us-ascii or iso-2022-jp encoded file, and convert non-interpretable
characters to utf-8 replacement?


-- 
Danh


Re: Subject that ends with UTF-8, 85 or A0 加

2022-08-02 Thread Dennis Preiser
On Tue, Aug 02, 2022 at 12:39:06PM +0200, Bastian wrote:
> I see it in the subject now.
> There are two U+FFFD chars.
> 
>> | System: Darwin 21.6.0 (arm64)
>> | ncurses: ncurses 6.3.20220625 (compiled with 6.3)
>> | libiconv: 1.16
>> | hcache backend: lmdb LMDB 0.9.70: (December 19, 2015)
>> | 
>> | Compiler:
>> | Apple clang version 13.1.6 (clang-1316.0.21.2.5)
>> | Target: arm64-apple-darwin21.5.0
>> | Thread model: posix
>> | [...]
> 
> Maybe some local vim/encoding issues on darwin?

Maybe. Interestingly, if I change the subject via 's' before sending in
mutt and replace the two replacement characters with 0x52a0 it works.

Dennis


Re: Subject that ends with UTF-8, 85 or A0 ��

2022-08-02 Thread Bastian
> > I can't reproduce either.
> 
> I can reproduce the issue. In vim the character 0x52a0 is still present:
> 
> <http://d--p.de/tmp/2022-08-02_vim.png>
> 
> After quitting vim, mutt displays the unicode replacement character
> 0xfffd instead of 0x52a0:

I see it in the subject now.
There are two U+FFFD chars.

> | System: Darwin 21.6.0 (arm64)
> | ncurses: ncurses 6.3.20220625 (compiled with 6.3)
> | libiconv: 1.16
> | hcache backend: lmdb LMDB 0.9.70: (December 19, 2015)
> | 
> | Compiler:
> | Apple clang version 13.1.6 (clang-1316.0.21.2.5)
> | Target: arm64-apple-darwin21.5.0
> | Thread model: posix
> | [...]

Maybe some local vim/encoding issues on darwin?

-- 
Bastian


Re: Subject that ends with UTF-8, 85 or A0 �

2022-08-02 Thread Dennis Preiser
On Tue, Aug 02, 2022 at 04:04:07PM +0700, Đoàn Trần Công Danh wrote:
> On 2022-08-02 10:06:08+0200, Bastian  wrote:
>> On 02Aug22 15:52+0900, Kenichi Asai wrote:
>> > Would it be possible to somehow avoid this problem?  I cannot avoid
>> > creating e-mails with Japanese characters in Subject and this problem
>> > bugs me quite much.
>> 
>> I think I am not able to reproduce this behavior. I appended 0x52A0 to 
>> the subject line. Can you verify?
> 
> I can't reproduce either.

I can reproduce the issue. In vim the character 0x52a0 is still present:

<http://d--p.de/tmp/2022-08-02_vim.png>

After quitting vim, mutt displays the unicode replacement character
0xfffd instead of 0x52a0:

<http://d--p.de/tmp/2022-08-02_mutt_before_sending.png>

Finally, in the e-mail as such this character has completely
disappeared:

<http://d--p.de/tmp/2022-08-02_mutt_after_sending.png>

| % mutt -v
| Mutt 2.2.6 (2022-06-05)
| Copyright (C) 1996-2022 Michael R. Elkins and others.
| Mutt comes with ABSOLUTELY NO WARRANTY; for details type `mutt -vv'.
| Mutt is free software, and you are welcome to redistribute it
| under certain conditions; type `mutt -vv' for details.
| 
| System: Darwin 21.6.0 (arm64)
| ncurses: ncurses 6.3.20220625 (compiled with 6.3)
| libiconv: 1.16
| hcache backend: lmdb LMDB 0.9.70: (December 19, 2015)
| 
| Compiler:
| Apple clang version 13.1.6 (clang-1316.0.21.2.5)
| Target: arm64-apple-darwin21.5.0
| Thread model: posix
| [...]

Dennis


Re: Subject that ends with UTF-8, 85 or A0 加

2022-08-02 Thread Bastian
On 02Aug22 16:04+0700, Đoàn Trần Công Danh wrote:
> On 2022-08-02 10:06:08+0200, Bastian  wrote:
> > υ 0x3C5
> > % 0xFF05
> > e 0xFF45
> > ム 0x30E0
> > 加 0x52A0
> > 
> > So only the last matches your description 'last byte is A0'
> 
> I think he meant the last byte of their utf-8 representation:
> Which means: υ 0x3C5 is 0xCF 0x85 which is ended with 0x85.

Thanks. TIL some more about utf8. When the pointer is ontop of a 
cahracter, vim shows me the character value as '0x3C5', which is the
'unicode code point'. On the utf8 chartable it is noted as 
U+03C5 and the according utf8 hex is 0xcf85.

-- 
Bastian


Re: Subject that ends with UTF-8, 85 or A0 加

2022-08-02 Thread Đoàn Trần Công Danh
On 2022-08-02 10:06:08+0200, Bastian  wrote:
> On 02Aug22 15:52+0900, Kenichi Asai wrote:
> > - prepare .mutt/muttrc containing only the following line:
> >   set edit_headers=yes
> > - launch mutt and type m to create a new mail.
> > - enter some e-mail address and a subject.
> > - vim launches.
> > - edit Subject line so that it ends with a character such as:
> >   υ or % or e (whose last byte of their UTF-8 code is 85) or
> >   ム or 加 (whose last byte of their UTF-8 code is A0).
> 
> The mail I received shows the characters you gave here as examples as:
> 
> υ 0x3C5
> % 0xFF05
> e 0xFF45
> ム 0x30E0
> 加 0x52A0
> 
> So only the last matches your description 'last byte is A0'

I think he meant the last byte of their utf-8 representation:
Which means: υ 0x3C5 is 0xCF 0x85 which is ended with 0x85.


> I cannot see them currently, my font does not support them. But anyways 
> I couldn't verify if these would be the characters you intended to send.
> 
> > Would it be possible to somehow avoid this problem?  I cannot avoid
> > creating e-mails with Japanese characters in Subject and this problem
> > bugs me quite much.
> 
> I think I am not able to reproduce this behavior. I appended 0x52A0 to 
> the subject line. Can you verify?

I can't reproduce either.

-- 
Danh


Re: Subject that ends with UTF-8, 85 or A0 加

2022-08-02 Thread Bastian
On 02Aug22 15:52+0900, Kenichi Asai wrote:
> - prepare .mutt/muttrc containing only the following line:
>   set edit_headers=yes
> - launch mutt and type m to create a new mail.
> - enter some e-mail address and a subject.
> - vim launches.
> - edit Subject line so that it ends with a character such as:
>   υ or % or e (whose last byte of their UTF-8 code is 85) or
>   ム or 加 (whose last byte of their UTF-8 code is A0).

The mail I received shows the characters you gave here as examples as:

υ 0x3C5
% 0xFF05
e 0xFF45
ム 0x30E0
加 0x52A0

So only the last matches your description 'last byte is A0'
I cannot see them currently, my font does not support them. But anyways 
I couldn't verify if these would be the characters you intended to send.

> Would it be possible to somehow avoid this problem?  I cannot avoid
> creating e-mails with Japanese characters in Subject and this problem
> bugs me quite much.

I think I am not able to reproduce this behavior. I appended 0x52A0 to 
the subject line. Can you verify?


Cheers,
-- 
Bastian


Subject that ends with UTF-8, 85 or A0

2022-08-02 Thread Kenichi Asai
When the subject ends with a character whose last byte in
UTF-8 is either 85 or A0, it appears the character collapses.
To reproduce:

- prepare .mutt/muttrc containing only the following line:
  set edit_headers=yes
- launch mutt and type m to create a new mail.
- enter some e-mail address and a subject.
- vim launches.
- edit Subject line so that it ends with a character such as:
  υ or % or e (whose last byte of their UTF-8 code is 85) or
  ム or 加 (whose last byte of their UTF-8 code is A0).
- type :wq to quit vim.
- the last character is converted to something else.

Would it be possible to somehow avoid this problem?  I cannot avoid
creating e-mails with Japanese characters in Subject and this problem
bugs me quite much.

I am using Mutt 2.2.3 (2022-04-12) installed from homebrew on MacOS
Big Sur 11.6.7 on iMac (2019).

Sincerely,

-- 
Kenichi Asai


Re: How to warn before sending email if "Subject:" is empty

2021-12-28 Thread Ed Blackman
On Fri, Dec 24, 2021 at 05:18:57AM +, Sam Lee via Mutt-users wrote:
> Is it possible to make Mutt warn about an empty "Subject:" right before
> sending the email?
> 
> The `abort_nosubject` configuration variable is not relevant here
> because `abort_nosubject` is only for configuring what happens when
> there is no subject given at the subject prompt.
> 
> I am looking for something similar to `abort_noattach`'s
> "No attachments, cancel sending?" warning that appears right before
> email is sent. Is there something similar for warning about an empty
> "Subject:"?

I don't believe it's possible directly with Mutt configuration, but if you send 
via sendmail (instead of SMTP), you can do that with the sendmail command 
instead, replacing it with a script that checks the email it's about to send, 
and aborts with a message if it has an empty Subject: line.

I have a similar script that, among other things, checks that I actually have 
attachments when I have "attach" or "patch" in my body text.

If you send via SMTP, I don't think you can hook into send like that.  You 
could change your editor to a script that 1) calls the real editor then 2) 
checks for an empty Subject:.  That would not prevent you from removing it in 
Mutt compose window afterward, though.

-- 
Ed Blackman


How to stop Mutt from prompting for Subject

2021-12-23 Thread Sam Lee via Mutt-users
When I want to compose a new email, Mutt will prompt for the recipients
("To:"), followed by the subject ("Subject:"). How do I disable the
prompting for the subject? The `autoedit` configuration option will not
help here because it disables both prompts (i.e. both "To:" and
"Subject:"). I only want to disable the "Subject:" prompt. How can I do
this in Mutt?


How to warn before sending email if "Subject:" is empty

2021-12-23 Thread Sam Lee via Mutt-users
Is it possible to make Mutt warn about an empty "Subject:" right before
sending the email?

The `abort_nosubject` configuration variable is not relevant here
because `abort_nosubject` is only for configuring what happens when
there is no subject given at the subject prompt.

I am looking for something similar to `abort_noattach`'s
"No attachments, cancel sending?" warning that appears right before
email is sent. Is there something similar for warning about an empty
"Subject:"?


Re: subject-hook ?

2021-07-29 Thread Kevin J. McCarthy

On Thu, Jul 29, 2021 at 06:33:10PM +0200, Andy Spiegl wrote:

I was expecting that this would work:
send-hook '~s "URGENT"'   'my_hdr X-Priority: 1'


That does work.  Although you'll want to make sure it's turned off in 
other cases by having both lines:

  send-hook ~A  'unmy_hdr X-Priority'
  send-hook '~s URGENT' 'my_hdr X-Priority: 1'


but apparently (acc. to the man page) send-hook only matches the recipients.


A send-hook can't be use to modify the recipients or subject of the 
current email.  But it's fine for changing user headers.  See 
<http://www.mutt.org/doc/manual/#compose-flow> for an overview of the 
composition process.


--
Kevin J. McCarthy
GPG Fingerprint: 8975 A9B3 3AA3 7910 385C  5308 ADEF 7684 8031 6BDA


signature.asc
Description: PGP signature


subject-hook ?

2021-07-29 Thread Andy Spiegl
Hi mutt-lovers,

I just found that there seems to be no such thing as a subject-hook.

I was expecting that this would work:
 send-hook '~s "URGENT"''my_hdr X-Priority: 1'
but apparently (acc. to the man page) send-hook only matches the recipients.

Do you know of any other way to hook to a matched subject?

Thanks,
 Andy


-- 
 The hardest thing in the world to understand is the income tax.
   (Albert Einstein)


Re: Adding text to subject when calling group

2021-06-09 Thread dvalin

 On 09.06.21 12:15, steve wrote:
> Hello,
> 
> Nobody for this one?
> 
> I found that I could modify the subject with a folder-hook but
that's
> only half of the solution since it doesn't take care of the group
alias
> part.
> 
> Any help would be highly appreciated.

I'd try a message-hook with pattern:

%C GROUP  │messages either to: or cc: to any member of GROUP

Have a look at "Table 4.4. Pattern modifiers" under the heading
"3.1. Pattern Modifier" in the manual. (On key F1 in mutt.)

I'd need a quick read of section "6. Using Hooks", for the header
edit, asit's a while since I last wrote one. IIRC, send-hooks &
message-hooks are 
triggered prior to composing a message, so if you have "set
edit_headers=yes", 
then your modified header ought to show in the edit session. (Not
tried.)

Erik



Re: Adding text to subject when calling group

2021-06-09 Thread steve

Hello,

Nobody for this one?

I found that I could modify the subject with a folder-hook but that's
only half of the solution since it doesn't take care of the group alias
part.

Any help would be highly appreciated.

Steve

Le 02-06-2021, à 08:54:50 +0200, steve a écrit :


Hi,

In the alias file, I defined several users and with them defined a group
'groupX'. When creating a new message with 'm' and calling 'groupX', I
would like to add a fixed text to the subject line (only when the alias
'groupX' is called').

How could I do that? I failed to find that particular usecase on the
Net.

Thanks

Steve


Adding text to subject when calling group

2021-06-02 Thread steve

Hi,

In the alias file, I defined several users and with them defined a group
'groupX'. When creating a new message with 'm' and calling 'groupX', I
would like to add a fixed text to the subject line (only when the alias
'groupX' is called'). 


How could I do that? I failed to find that particular usecase on the
Net.

Thanks

Steve


Mailman strips subject from DMARC messages (was: Re: Fwd:)

2021-02-16 Thread Sam Kuper
On Sat, Oct 24, 2020 at 12:49:12PM -0700, Kevin J. McCarthy wrote:
> On Sat, Oct 24, 2020 at 12:24:23PM -0700, Kevin J. McCarthy wrote:
>> On Sat, Oct 24, 2020 at 02:04:11PM -0400, Remco Rijnders wrote:
>>> Unfortunately, the subject of such messages seems to get cleared.  I
>>> don't think this is something under our control but of the generous
>>> people who host the mutt-users mailing list for the project. Kevin,
>>> do you know if this is anything that can be changed / fixed?
>>
>> Whoops, I missed the fact that the wrapper removes the Subject line
>> too.  That's not convenient at all.  Let me see if there is anything
>> I can do about that.
> 
> I didn't see any options regarding the wrapper Subject header, so I've
> changed the action to munge the From address instead.

Mailman's failure to retain the Subject: header when wrapping a
DMARC message was a bug, and the Mailman maintainer has issued a patch:

https://mail.python.org/archives/list/mailman-us...@python.org/thread/ZVM6I4UTDKHY4EKNLIBIWE4JNC2PYLIS/

-- 
A: When it messes up the order in which people normally read text.
Q: When is top-posting a bad thing?

()  ASCII ribbon campaign. Please avoid HTML emails & proprietary
/\  file formats. (Why? See e.g. https://v.gd/jrmGbS ). Thank you.


Re: list messages with emojis in subject line? 

2021-02-05 Thread Francesco Ariis
Il 05 febbraio 2021 alle 12:25 Will Yardley ha scritto:
> On Fri, Feb 05, 2021 at 11:12:32AM -0800, Aleksandr Miroslav wrote:
> > What filter can I use to only show messages that contain emojis in the
> > subject line?
> > 
> > For me, these are almost always spam, so I would like to quickly
> > filter them out.
> 
> Seems like that might be challenging - even if Mutt decodes the subject
> first, I don't think it can look for specific ranges, and also, it seems
> as if there's no specific set of ranges to filter.
> 
> https://stackoverflow.com/questions/30470079/emoji-value-range

There is an «Emoji» property in the Unicode standard, so assuming that OP
uses getmail (or procmail or similar) to fetch his mail, he could use an
external filter.
If the problem is spam, I would just train bmf [1]
—F

[1] https://jblevins.org/log/bmf


Re: list messages with emojis in subject line? 

2021-02-05 Thread Will Yardley
On Fri, Feb 05, 2021 at 11:12:32AM -0800, Aleksandr Miroslav wrote:
> What filter can I use to only show messages that contain emojis in the
> subject line?
> 
> For me, these are almost always spam, so I would like to quickly
> filter them out.

Seems like that might be challenging - even if Mutt decodes the subject
first, I don't think it can look for specific ranges, and also, it seems
as if there's no specific set of ranges to filter.

https://stackoverflow.com/questions/30470079/emoji-value-range

It might be easier to make a character set of characters you do want,
and look for messages that contain at least one character that's not in
that set.

For example, for me, this seems to roughly work for most of the mail
that I see, except that it includes emails with Chinese characters in
the subject or an empty subject. But you might be able to dial that in
to something close to what you want.
!~s "[0-9a-z _! ]+"

I don't know if my system is misconfigured, but I don't actually see
emojis in the pager of mutt, though I do see them in vim if I edit a
message.

w



list messages with emojis in subject line?

2021-02-05 Thread Aleksandr Miroslav
What filter can I use to only show messages that contain emojis in the
subject line?

For me, these are almost always spam, so I would like to quickly
filter them out.

thanks
Alex


[no subject]

2020-10-24 Thread Globe Trotter via Mutt-users
This message wraps the original message.

The sending domain has a DMARC p=reject policy, which unfortunately
can cause bounces.  See http://www.mutt.org/mail-lists.html#dmarc

To remove this message, please change the domain policy to p=none or
p=quarantine.--- Begin Message ---
Thanks, this works for me! Thanks also to Remco.


On Saturday, October 24, 2020, 12:24:15 PM CDT, Felix Finch  
wrote: 





On 20201024, Globe Trotter via Mutt-users wrote:

>
>An irritating thing right now is that if I hit q in error after composing a 
>message, I get: Postpone message (yes/no) and if I say no, then the message 
>appears lost. Is is possible to have an an option on this which should be to 
>cancel the postpone question:  perhaps a prompt that is [yes/no/cancel]


Try ^G.  I just tried it on this message and it does cancel the quit.  You do 
have to type "e" to get back to editing.

Or go ahead and postpone, then type "m" to send a new message.  This notices 
the draft and asks if you want to work on that.

-- 
            ... _._. ._ ._. . _._. ._. ___ .__ ._. . .__. ._ .. ._.
    Felix Finch: scarecrow repairman & wood chipper / fe...@crowfix.com
  GPG = E987 4493 C860 246C 3B1E  6477 7838 76E9 182E 8151 ITAR license #4933
I've found a solution to Fermat's Last Theorem but I see I've run out of room o
--- End Message ---


[no subject]

2020-10-24 Thread Globe Trotter via Mutt-users
This message wraps the original message.

The sending domain has a DMARC p=reject policy, which unfortunately
can cause bounces.  See http://www.mutt.org/mail-lists.html#dmarc

To remove this message, please change the domain policy to p=none or
p=quarantine.--- Begin Message ---

  > On Saturday, October 24, 2020, 11:33:57 AM CDT, Remco Rijnders 
 wrote: 
> I got that mixed up indeed, apologies! The manual does mention it, but 
> perhaps not in the easiest searchable way:
> 3.347. sort_aux
> (...)> You can also specify the “last-” prefix in addition to the “reverse-” 
> prefix, but “last-” must come after “reverse-”. The “last-” prefix causes 
> messages to be sorted against its siblings by which has the last descendant, 
> using the rest of $sort_aux as an ordering.

Oh, thanks very much for this additional information. This is very helpful!!




--- End Message ---


[no subject]

2020-10-24 Thread Globe Trotter via Mutt-users
This message wraps the original message.

The sending domain has a DMARC p=reject policy, which unfortunately
can cause bounces.  See http://www.mutt.org/mail-lists.html#dmarc

To remove this message, please change the domain policy to p=none or
p=quarantine.--- Begin Message ---
Hi,

An irritating thing right now is that if I hit q in error after composing a 
message, I get: Postpone message (yes/no) and if I say no, then the message 
appears lost. Is is possible to have an an option on this which should be to 
cancel the postpone question:  perhaps a prompt that is [yes/no/cancel]

Thanks!
--- End Message ---


[no subject]

2020-10-24 Thread Globe Trotter via Mutt-users
This message wraps the original message.

The sending domain has a DMARC p=reject policy, which unfortunately
can cause bounces.  See http://www.mutt.org/mail-lists.html#dmarc

To remove this message, please change the domain policy to p=none or
p=quarantine.--- Begin Message ---
On Saturday, October 24, 2020, 11:07:41 AM CDT, Remco Rijnders 
 wrote: 

On Sat, Oct 24, 2020 at 03:09:06PM +, Globe wrote in 
:
>
>Looking at: http://www.mutt.org/doc/manual/manual.html#sort, it seems to me 
>that I should simply
>
>set sort=threads
>set sort_aux=reverse-date-received
>
>However, what I get is the threads, correctly, but the ones with most recent 
>messages do not come up first. I want the threads with most recent activity 
>coming up first. Can this be done in mutt? (I do not want reverse_threads.)

> Try changing the sort_aux to:

> set sort_aux=last-reverse-date-received

> Does that what you want? Without "last" it looks at the date of the first 
> message in the thread, with it, it uses the last one of all the messages.

Thanks! For me, and also from the manual, I don't find this method: 

Error in /home/gt/.muttrc, line 187: reverse-date-received: unknown sorting 
method

Perhaps, you meant: 

set sort_aux=reverse-last-date-received

which I tried as a guess, even though it does not seem to be in the manual but 
does not give an error and seems to work. Thanks!!

--- End Message ---


[no subject]

2020-10-24 Thread Globe Trotter via Mutt-users
This message wraps the original message.

The sending domain has a DMARC p=reject policy, which unfortunately
can cause bounces.  See http://www.mutt.org/mail-lists.html#dmarc

To remove this message, please change the domain policy to p=none or
p=quarantine.--- Begin Message ---
Hi,

Looking at: http://www.mutt.org/doc/manual/manual.html#sort, it seems to me 
that I should simply 

set sort=threads
set sort_aux=reverse-date-received

However, what I get is the threads, correctly, but the ones with most recent 
messages do not come up first. I want the threads with most recent activity 
coming up first. Can this be done in mutt? (I do not want reverse_threads.)

Sorry if my question is unclear.

Thanks,
GT
--- End Message ---


[no subject]

2020-10-23 Thread Globe Trotter via Mutt-users
This message wraps the original message.

The sending domain has a DMARC p=reject policy, which unfortunately
can cause bounces.  See http://www.mutt.org/mail-lists.html#dmarc

To remove this message, please change the domain policy to p=none or
p=quarantine.--- Begin Message ---
On Friday, October 23, 2020, 10:38:00 AM CDT, Remco Rijnders 
 wrote: 


>> I want to set bcc to my address for every e-mail I send from an account. How 
>> do I do that? Do I define a hook?


> You could use a hook for it, but it might be simpler to use the record 
> functionality. See http://www.mutt.org/doc/manual/#record for how to 
> automatically save a copy of every outgoing message to a folder of your 
> choice.


Thank you for this.I also set Bcc because it gives me an indication that the 
message actually went out/through. How do I specify this hook?

Thank you again!
GT
--- End Message ---


[no subject]

2020-10-23 Thread Globe Trotter via Mutt-users
This message wraps the original message.

The sending domain has a DMARC p=reject policy, which unfortunately
can cause bounces.  See http://www.mutt.org/mail-lists.html#dmarc

To remove this message, please change the domain policy to p=none or
p=quarantine.--- Begin Message ---

On Friday, October 23, 2020, 9:33:13 AM CDT, Remco Rijnders 
 wrote: 

> Hi Globe,

> Please see http://www.mutt.org/doc/manual/#sidebar-sort-method for a list of 
> options for sorting your sidebar. It probably is a good idea to refer to this 
> official mutt manual in general for supported options as some of the "how 
> to"'s and tricks you can find on the internet might be outdated.  I hope this 
> helps!

> Kind regards,

Remco,

Thanks very much! This is very helpful.

Best regards,
GT

--- End Message ---


[no subject]

2020-10-23 Thread Globe Trotter via Mutt-users
This message wraps the original message.

The sending domain has a DMARC p=reject policy, which unfortunately
can cause bounces.  See http://www.mutt.org/mail-lists.html#dmarc

To remove this message, please change the domain policy to p=none or
p=quarantine.--- Begin Message ---
Hi,

I want to set bcc to my address for every e-mail I send from an account. How do 
I do that? Do I define a hook?

Thanks!
--- End Message ---


[no subject]

2020-10-23 Thread Globe Trotter via Mutt-users
This message wraps the original message.

The sending domain has a DMARC p=reject policy, which unfortunately
can cause bounces.  See http://www.mutt.org/mail-lists.html#dmarc

To remove this message, please change the domain policy to p=none or
p=quarantine.--- Begin Message ---
Hi,

New to mutt but I put the following in my .muttrc file, as per examples online:



set sort_sidebar = desc



However, when I start mutt, I get:



Error in /home/gt/.muttrc, line 217: sort_sidebar: unknown variable

source: errors in /home/gt/.muttrc

Press any key to continue...



Is sort_sidebar deprecated in mutt?



Thanks,

GT
--- End Message ---


[no subject]

2020-10-23 Thread Globe Trotter via Mutt-users
This message wraps the original message.

The sending domain has a DMARC p=reject policy, which unfortunately
can cause bounces.  See http://www.mutt.org/mail-lists.html#dmarc

To remove this message, please change the domain policy to p=none or
p=quarantine.--- Begin Message ---
Hi,
New to mutt but I put the following in my .muttrc file: 

set sort_sidebar = desc

However, when I start mutt, I get: 

Error in /home/gt/.muttrc, line 217: sort_sidebar: unknown variable
source: errors in /home/gt/.muttrc
Press any key to continue...

Is sort_sidebar deprecated in mutt? 

Thanks,
GT
--- End Message ---


[no subject]

2020-10-21 Thread Globe Trotter via Mutt-users
This message wraps the original message.

The sending domain has a DMARC p=reject policy, which unfortunately
can cause bounces.  See http://www.mutt.org/mail-lists.html#dmarc

To remove this message, please change the domain policy to p=none or
p=quarantine.--- Begin Message ---
My aoologies for the earlier attempts at sending e-mail. But I am new to mutt 
(as of today) and do not have my mailer set up  and trying to get started. I 
hope this goes through in plain-text format.

My set up is as follows: I use fetchmail and procmail to get my mail delivered 
to Maildir mailboxes. So,my mail is inside folders in ~/Maildir in the 
following manner:


~/Maildir/inbox
~/Maildir/sent
~/Maildir/drafts
~/Maildir/work/
~/Maildir/work/user1
~/Maildir/work/user2
~/Maildir/bills
~/Maildir/family


etc. I want to show this tree on a side-pane. So, my initial attempt at .muttrc 
has the following: modified from mutt & Maildir Mini-HOWTO


set mbox_type=Maildir
set folder="~/Maildir"
mailboxes `echo -n "+ "; find ~/Maildir -type d -name "*" -printf "+'%f' "`


However, when I launch mutt, I get nothing and after a lot of blank stares 
on-screen, I get: Mutt:/var/spool/mail/itsme [Msgs: 0 Inc: 
20](date/date)(all)--



I was wondering if I could get some advice and help on how to do this. I plan 
on sending mail through postfix (localhost:25). 


My apologies for my questions and thank you for your help!


GT



--- End Message ---


[no subject]

2020-10-21 Thread Globe Trotter via Mutt-users
This message wraps the original message.

The sending domain has a DMARC p=reject policy, which unfortunately
can cause bounces.  See http://www.mutt.org/mail-lists.html#dmarc

To remove this message, please change the domain policy to p=none or
p=quarantine.--- Begin Message ---
Hi,
Sorry I am very new (as of today) to mutt and I am trying to get started. 

My set up is as follows: I use fetchmail and procmail to get my mail delivered 
to Maildir mailboxes. So,my mail is inside folders in ~/Maildir in the 
following manner:
~/Maildir/inbox~/Maildir/sent~/Maildir/drafts
~/Maildir/work/~/Maildir/work/user1~/Maildir/work/user2~/Maildir/bills~/Maildir/family
etc. I want to show this tree on a side-pane. So, my initial attempt at .muttrc 
has the following: modified from mutt & Maildir Mini-HOWTO
set mbox_type=Maildir
set folder="~/Maildir"
mailboxes `echo -n "+ "; find ~/Maildir -type d -name "*" -printf "+'%f' "`

However, when I launch mutt, I get nothing and after a lot of blank stares 
on-screen, I get: Mutt:/var/spool/mail/itsme [Msgs: 0 Inc: 
20](date/date)(all)-- 

I was wondering if I could get some help.
My apologies for my questions and thank you for your help!
GT



--- End Message ---


[no subject]

2020-10-21 Thread Globe Trotter via Mutt-users
This message wraps the original message.

The sending domain has a DMARC p=reject policy, which unfortunately
can cause bounces.  See http://www.mutt.org/mail-lists.html#dmarc

To remove this message, please change the domain policy to p=none or
p=quarantine.--- Begin Message ---
Hi,
Sorry I am very new (as of today) to mutt and I am trying to get started. 

My set up is as follows: I use fetchmail and procmail to get my mail delivered 
to Maildir mailboxes. So,my mail is inside folders in ~/Maildir in the 
following manner:
~/Maildir/inbox~/Maildir/sent~/Maildir/drafts
~/Maildir/work/~/Maildir/work/user1~/Maildir/work/user2~/Maildir/bills~/Maildir/family
etc. I want to show this tree on a side-pane. So, my initial attempt at .muttrc 
has the following: modified from mutt & Maildir Mini-HOWTO

| 
| 
|  | 
mutt & Maildir Mini-HOWTO


 |

 |

 |



set mbox_type=Maildir
set folder="~/Maildir"
mailboxes `echo -n "+ "; find ~/Maildir -type d -name "*" -printf "+'%f' "`

However, when I launch mutt, I get nothing and after a lot of blank stares 
on-screen, I get: Mutt:/var/spool/mail/itsme [Msgs: 0 Inc: 
20](date/date)(all)-- 

I was wondering if I could get some help.
My apologies for my questions and thank you for your help!
GT

--- End Message ---


[no subject]

2020-10-18 Thread Paul Gilmartin via Mutt-users
This message wraps the original message.

The sending domain has a DMARC p=reject policy, which unfortunately
can cause bounces.  See http://www.mutt.org/mail-lists.html#dmarc

To remove this message, please change the domain policy to p=none or
p=quarantine.--- Begin Message ---
AOL and Yahoo have been warning me that there will be
new security procedures in a couple days.

I access AOL and Yahoo with IMAP/SMTP.

How will this affect my (infrequent) use of these
services with Mutt?

URLs:
https://uk.help.yahoo.com/kb/new-mail-for-desktop/SLN27791.html?impressions=true#others
https://help.aol.com/articles/allow-apps-that-use-less-secure-sign-in#others

Thanks,
gil

--- End Message ---


[no subject]

2020-09-01 Thread Paul Gilmartin via Mutt-users
This message wraps the original message.

The sending domain has a DMARC p=reject policy, which unfortunately
can cause bounces.  See http://www.mutt.org/mail-lists.html#dmarc

To remove this message, please change the domain policy to p=none or
p=quarantine.--- Begin Message ---
On 2020-09-01, at 10:49:22, Jon LaBadie wrote:
> 
> On Mon, Aug 31, 2020 at 01:06:48PM -0400, Mark H. Wood wrote:
>> 
>> 
>> It's easy to edit documents in a revisable format until they are
>> satisfactory, and then render the finished content in a final format
>> (or multiple final formats) for publication.
> 
> Good point Mark.  And certainly my need is distribution of a finalized
> document.  I've kinda decided to create the 2 columns of seating
> assignments using a text editor and shell tools.  This will be the
> main part of the email msg body.  That will also be pasted into an
> "odt" document, some formatting and boiler plate added, then exported
> as a "pdf" for attachment to the email.
>  
If you have LibreOffice, consider editing to a .csv; importing to
LibreOffice as a spreadsheed, and exporting as .pdf (or .html).

A shell tool might automate converting plain text to .csv.

-- gil

--- End Message ---


[no subject]

2020-08-27 Thread Paul Gilmartin via Mutt-users
This message wraps the original message.

The sending domain has a DMARC p=reject policy, which unfortunately
can cause bounces.  See http://www.mutt.org/mail-lists.html#dmarc

To remove this message, please change the domain policy to p=none or
p=quarantine.--- Begin Message ---
(Plus one Bcc:)

On 2020-08-26, at 23:40:08, Jon LaBadie wrote:
> 
> For so long I've used mutt and composed my emails in ASCII,
> now I guess Unicode, that I'm ignorant of potential approaches
> to a bit of formatted text.
>  
The needed symbols seem to exist in Unicode:
https://en.wikipedia.org/wiki/Playing_cards_in_Unicode

> Both a friend and I organize weekly online bridge games for
> 20-30 players.  My seating notices go out as simple text.  He
> creates a 2 column Word document and includes it as an attachment.
> Players who wish to see his seatings must use an external office
> suite to view the attachment.
>  
One thing I think of is a spreadsheet, packaged as a .csv.  It's
marginally legible as text or either Windows Excel or MacOS
Numbers should render it.  An alternative is the attractively
priced LibreOffice.

> Is there anything I could use to create such "formated text", then
> distribute it in the body of a mutt message having some hope that
> the recipients see it correctly?
>  
Is there an example to try?  If it exists as .xlsx it could
be exported as .csv

-- gil

--- End Message ---


Re: [Mutt] Re: [Mutt] Re: Long subject lines

2018-08-19 Thread David Woodfall
On Sunday 19 August 2018 18:38,
Mihai Lazarescu  put forth the proposition:
> On Sunday, August 19, 2018 at 14:57:20 +0100, David Woodfall wrote:
>
> > On Sunday 19 August 2018 13:58, Mihai Lazarescu  put 
> > forth the proposition:
> >
> > > BTW, piping the message through "formail -c" would
> > > concatenate continued fields in the header.
> >
> > Can I add a pipe to the editor command somehow, or how would
> > I go about it?
>
> I'd do the pipe in vim — you were using vim, right? Something like:
>
> autocmd BufRead /tmp/mutt-* silent! normal ggV}k!formail -fc^M}dd
>
> where ^M is actually the ASCII 13 Ctrl-M (carriage return) control character.
>
> Mihai
>

OK. Thanks.

Dave

--

'Mounting' is used for three things: climbing on a horse, linking in a
hard disk unit in data systems, and, well, mounting during sex.
  -- Christa Keil

.--.  oo
   ()//
~'


Re: [Mutt] Re: [Mutt] Re: Long subject lines

2018-08-19 Thread Mihai Lazarescu

On Sunday, August 19, 2018 at 14:57:20 +0100, David Woodfall wrote:


On Sunday 19 August 2018 13:58, Mihai Lazarescu  put forth 
the proposition:

> BTW, piping the message through "formail -c" would
> concatenate continued fields in the header.

Can I add a pipe to the editor command somehow, or how would
I go about it?


I'd do the pipe in vim — you were using vim, right? 
Something like:


autocmd BufRead /tmp/mutt-* silent! normal ggV}k!formail -fc^M}dd

where ^M is actually the ASCII 13 Ctrl-M (carriage return) 
control character.


Mihai


Re: [Mutt] Re: Long subject lines

2018-08-19 Thread David Woodfall
On Sunday 19 August 2018 13:58,
Mihai Lazarescu  put forth the proposition:
> On Sunday, August 19, 2018 at 10:33:35 +0100, David Woodfall wrote:
>
> > It was kind of an xy problem really.  My vim function that
> > gets called when I edit a message needs fixing for subjects
> > of 1 line.  Or it will drop me in insert mode after the first
> > line, and the second and any subsequent lines are under that.
> >
> > Easy to fix anyway, but this is the first time that it's
> > happened so it was a bit of a surprise.
>
> BTW, piping the message through "formail -c" would concatenate continued 
> fields in
> the header.
>
> Mihai

Can I add a pipe to the editor command somehow, or how would I go
about it?

--

I'm telling you that the kernel is stable not because it's a kernel,
but because I refuse to listen to arguments like this.
  -- Linus Torvalds

.--.  oo
   ()//
~'


Re: [Mutt] Re: Long subject lines

2018-08-19 Thread Mihai Lazarescu

On Sunday, August 19, 2018 at 10:33:35 +0100, David Woodfall wrote:


It was kind of an xy problem really.  My vim function that
gets called when I edit a message needs fixing for subjects
of 1 line.  Or it will drop me in insert mode after the first
line, and the second and any subsequent lines are under that.

Easy to fix anyway, but this is the first time that it's
happened so it was a bit of a surprise.


BTW, piping the message through "formail -c" would concatenate 
continued fields in the header.


Mihai


Re: Long subject lines

2018-08-19 Thread David Woodfall
On Sunday 19 August 2018 16:52,
Erik Christiansen  put forth the proposition:
> On 19.08.18 03:17, David Woodfall wrote:
> > I sent a message with a rather long subject line earlier and it was
> > split into two lines.
>
> OK, I'm a laggard, still on mutt 1.8.0, but when I compose a three-line
> subject in vim¹, separated by newlines, it is visually _joined_ into a
> single line on return to mutt. Sending it to myself, it is displayed as
> three lines in mutt, but more compact than composed. That may just be
> wrapping of the single line.
>
> The only other MUA I have any familiarity with is ancient "mail", and it
> shows the same for the received message.
>
> > Is there a way to avoid that? I tried setting tw=0 in an autocmd in
> > vim but it still got cut. I checked that tw was still set to 0, so I
> > assume that mutt cuts it before vim opens it.
>
> Seeing three lines in vim being joined to one in mutt, I don't expect
> vim settings to have much effect in the MUA.
>
> > Or is this a limitation of the RFC that subject lines need to be
> > under a certain length?
>
> My simple experiments suggest that it's just mutt joining vim's multiple
> lines into one, then wrapping that for useful display on receipt.
>
> Erik
>
> ¹ edit_headers is set.

It was kind of an xy problem really. My vim function that gets called
when I edit a message needs fixing for subjects of > 1 line. Or it
will drop me in insert mode after the first line, and the second and
any subsequent lines are under that.

Easy to fix anyway, but this is the first time that it's happened so
it was a bit of a surprise.

Dave

--

Never make any mistaeks.
  -- Anonymous, in a mail discussion about to a kernel bug report

.--.  oo
   ()//
~'


Re: Long subject lines

2018-08-19 Thread Erik Christiansen
On 19.08.18 03:17, David Woodfall wrote:
> I sent a message with a rather long subject line earlier and it was
> split into two lines.

OK, I'm a laggard, still on mutt 1.8.0, but when I compose a three-line
subject in vim¹, separated by newlines, it is visually _joined_ into a
single line on return to mutt. Sending it to myself, it is displayed as
three lines in mutt, but more compact than composed. That may just be
wrapping of the single line.

The only other MUA I have any familiarity with is ancient "mail", and it
shows the same for the received message.

> Is there a way to avoid that? I tried setting tw=0 in an autocmd in
> vim but it still got cut. I checked that tw was still set to 0, so I
> assume that mutt cuts it before vim opens it.

Seeing three lines in vim being joined to one in mutt, I don't expect
vim settings to have much effect in the MUA.

> Or is this a limitation of the RFC that subject lines need to be
> under a certain length?

My simple experiments suggest that it's just mutt joining vim's multiple
lines into one, then wrapping that for useful display on receipt.

Erik

¹ edit_headers is set.


Re: [Mutt] Long subject lines

2018-08-19 Thread David Woodfall
On Sunday 19 August 2018 08:25,
Mihai Lazarescu  put forth the proposition:
> On Sunday, August 19, 2018 at 03:17:58 +0100, David Woodfall wrote:
>
> > Or is this a limitation of the RFC that subject lines need
> > to be under a certain length?
>
> Yes, RFC 5322.  Header lines cannot exceed 998 characters and should be 
> folded at less than 78
> character per line:
>
>https://tools.ietf.org/html/rfc5322#section-2.1.1
>
>https://tools.ietf.org/html/rfc5322#section-2.2.3
>
> Mihai

Thanks.

Dave

--

Go not unto the Usenet for advice, for you will be told both yea and nay (and
quite a few things that just have nothing at all to do with the question).
  -- seen in a .sig somewhere

.--.  oo
   ()//
~'


Re: [Mutt] Long subject lines

2018-08-19 Thread Mihai Lazarescu

On Sunday, August 19, 2018 at 03:17:58 +0100, David Woodfall wrote:


Or is this a limitation of the RFC that subject lines need
to be under a certain length?


Yes, RFC 5322.  Header lines cannot exceed 998 characters and 
should be folded at less than 78 character per line:


   https://tools.ietf.org/html/rfc5322#section-2.1.1

   https://tools.ietf.org/html/rfc5322#section-2.2.3

Mihai


Long subject lines

2018-08-18 Thread David Woodfall
I sent a message with a rather long subject line earlier and it was
split into two lines.

Is there a way to avoid that? I tried setting tw=0 in an autocmd in
vim but it still got cut. I checked that tw was still set to 0, so I
assume that mutt cuts it before vim opens it.

Or is this a limitation of the RFC that subject lines need to be
under a certain length?

--

As usual, this being a 1.3.x release, I haven't even compiled this
kernel yet.  So if it works, you should be doubly impressed.
  -- Linus Torvalds, announcing kernel 1.3.3

.--.  oo
   ()//
~'




Re: Remove Subject prefixing (when answering/forwarding) possible?

2018-03-02 Thread Erik Christiansen
On 28.02.18 12:10, Patrick Shanahan wrote:
> some time ago, in an earlier age, Sven Guckes posted a sed or perl filter
> to hide "Subject:" additions, but I seem to have lost it, and he seems to
> be missing too  :^(
> 

The following has served for so many years in my .procmailrc that I
can't recall if it was Sven who provided the method for _stripping_ that
cruft from the incoming subject header.

   :0
   * ^TO_luv-main@.*luv.asn.au
   {
    # We need the subject line _content_, minus [list-name]:

  SUBJECT=`formail -czX "Subject:" | sed -re "s/Subject:// ; s/ 
\[luv-[a-z]*\]//g"`
   
# Header filter leaves body alone:
  :0fhw
  | formail -i "Subject: $SUBJECT"
   
# Delivery, with lockfile:
  :0:
  luv-main
   }

The second sed regex could perhaps be generalised, rather than just
retargeted for your problem list, but a quick fix is a good fix, so
long as it does the job, I figure.

Changing "-i" to -I" on line 10 stops the received subject header being
retained as "Old-Subject:", but retaining it is a reminder that the post
has been trivially munged.

The ^TO_ on line 2 accepts either "To:" or "Cc:", as adjunct to simple
duplicates management via formail. (Forces "courtesy copy" to the list
mailbox.)

Erik


Re: Remove Subject prefixing (when answering/forwarding) possible?

2018-02-28 Thread Akkana Peck
Kevin J. McCarthy writes:
> On Wed, Feb 28, 2018 at 09:28:41AM -0700, Akkana Peck wrote:
> > But the example in the manual doesn't work for me in 1.9.3 [ ... ]
> >   subjectrx '\[[^\]]*\]? *' '%L%R'
> 
> Looks like the example might be wrong in the manual, unless there are
> regexp library differences.  Because ']' is first in the character
> class (after the negation), it shouldn't need to be escaped.  This works
> for me:
> subjectrx '\[[^]]*\]:? *' '%L%R'
> 
> If that works for you all, I'll fix up the manual example.

That works for me. Thanks, Kevin and Christian! Great feature.

...Akkana


Re: Remove Subject prefixing (when answering/forwarding) possible?

2018-02-28 Thread Kevin J. McCarthy
On Wed, Feb 28, 2018 at 07:05:19PM +0100, Matthias Apitz wrote:
> El día Wednesday, February 28, 2018 a las 10:00:29AM -0800, Kevin J. McCarthy 
> escribió:
> 
> > Looks like the example might be wrong in the manual, unless there are
> > regexp library differences.  Because ']' is first in the character
> > class (after the negation), it shouldn't need to be escaped.  This works
> > for me:
> > subjectrx '\[[^]]*\]:? *' '%L%R'
> > 
> > If that works for you all, I'll fix up the manual example.
> 
> The man page for muttrc should be checked/fixed to. On 1.8.0 I saw no
> hint about 'subjectrx'.

Thanks Matthias, I'll fix that up.  Also, my apologies Christian for
obliviously repeating what you had already pointed out as the problem.

-- 
Kevin J. McCarthy
GPG Fingerprint: 8975 A9B3 3AA3 7910 385C  5308 ADEF 7684 8031 6BDA


signature.asc
Description: PGP signature


Re: Remove Subject prefixing (when answering/forwarding) possible?

2018-02-28 Thread Matthias Apitz
El día Wednesday, February 28, 2018 a las 10:00:29AM -0800, Kevin J. McCarthy 
escribió:

> Looks like the example might be wrong in the manual, unless there are
> regexp library differences.  Because ']' is first in the character
> class (after the negation), it shouldn't need to be escaped.  This works
> for me:
> subjectrx '\[[^]]*\]:? *' '%L%R'
> 
> If that works for you all, I'll fix up the manual example.

The man page for muttrc should be checked/fixed to. On 1.8.0 I saw no
hint about 'subjectrx'.

Thanks

matthias
-- 
Matthias Apitz, ✉ g...@unixarea.de, ⌂ http://www.unixarea.de/   
+49-176-38902045
Public GnuPG key: http://www.unixarea.de/key.pub


Re: Remove Subject prefixing (when answering/forwarding) possible?

2018-02-28 Thread Kevin J. McCarthy
On Wed, Feb 28, 2018 at 09:28:41AM -0700, Akkana Peck wrote:
> Todd Zullinger writes:
> > http://www.mutt.org/doc/manual/#display-munging
> > 
> > subjectrx was added in 1.8.0, it seems.
> 
> That's wonderful! Something I've been wishing for for a long time.
> 
> But the example in the manual doesn't work for me in 1.9.3
> (on Debian testing, but I think that's back to being normal mutt,
> not neomutt, right?). This line in muttrc:
>   subjectrx '\[[^\]]*\]? *' '%L%R'

Looks like the example might be wrong in the manual, unless there are
regexp library differences.  Because ']' is first in the character
class (after the negation), it shouldn't need to be escaped.  This works
for me:
subjectrx '\[[^]]*\]:? *' '%L%R'

If that works for you all, I'll fix up the manual example.

Thanks!

-- 
Kevin J. McCarthy
GPG Fingerprint: 8975 A9B3 3AA3 7910 385C  5308 ADEF 7684 8031 6BDA


signature.asc
Description: PGP signature


Re: Remove Subject prefixing (when answering/forwarding) possible?

2018-02-28 Thread Ian Zimmerman
On 2018-02-28 12:10, Patrick Shanahan wrote:

> some time ago, in an earlier age, Sven Guckes posted a sed or perl
> filter to hide "Subject:" additions, but I seem to have lost it, and
> he seems to be missing too :^(

Here's what I do now as part of my incoming pipeline.  Of course, this
in fact _rewrites_ the email, not being just a filter for mutt display,
so it's not really what the OP is asking for.

$main::mail is a Mail::Audit instance constructed earlier in the
framework.

## <<15-degunk.pl

use Email::MIME::RFC2047::Decoder ;
use Email::MIME::RFC2047::Encoder ;

my $decoder = Email::MIME::RFC2047::Decoder->new;
my @encparms = (encoding => 'utf-8', method   => 'Q');
my $encoder = Email::MIME::RFC2047::Encoder->new(@encparms);
my $tagre = qr{\[[-_?a-zA-Z0-9/]+(\s+(list|forum|spam)|[?])?\]:?}i;
my $repre = qr{(re|fwd):}i;

my $subject = $main::mail->get('subject');

SUBJECT:
{
  do {
last SUBJECT unless $subject;
my $subject_dec = $decoder->decode_text($subject);
my $is_reply = 0;
my $prefixed = 0;
while ($subject_dec =~ /^($tagre|$repre)\h*/) {
  my $preflen = $+[0];
  $prefixed = 1;
  $is_reply = 1 if $subject_dec =~ m(^$repre)i;
  $subject_dec = substr $subject_dec, $preflen;
}
last SUBJECT unless $prefixed;
$subject_dec = 'Re: ' . $subject_dec if $is_reply;
my $subject_enc = $encoder->encode_text($subject_dec);

    $main::mail->add_header('X-Old-Subject' => $subject);
$main::mail->replace_header('Subject' => $subject_enc);
last SUBJECT;
  } while 1;
}

## >>15-degunk.pl


-- 
Please don't Cc: me privately on mailing lists and Usenet,
if you also post the followup to the list or newsgroup.
To reply privately _only_ on Usenet and on broken lists
which rewrite From, fetch the TXT record for no-use.mooo.com.


Re: Remove Subject prefixing (when answering/forwarding) possible?

2018-02-28 Thread Christian Ebert
* Patrick Shanahan on Wednesday, February 28, 2018 at 12:10:59 -0500 

some time ago, in an earlier age, Sven Guckes posted a sed or perl filter
to hide "Subject:" additions, but I seem to have lost it, and he seems to
be missing too  :^(


Something like

sed -e '1,/^$/ s/^Subject: *\(Re: *\)*\[[^]]*\] */Subject: \1/'

extended?

But displayfilter have no effect for the index, and I believe 
that's what subjectrx is for.


For replying/forwarding an editor script (vim in Sven's case).

--
LAST SHIP HOME
Die Weltumsegelung der Peter von Danzig
Ein Film von Michael Weber und Christian Ebert
--->> https://lastshiphome.de


Re: Remove Subject prefixing (when answering/forwarding) possible?

2018-02-28 Thread Patrick Shanahan
* Akkana Peck <akk...@shallowsky.com> [02-28-18 11:50]:
> Todd Zullinger writes:
> > http://www.mutt.org/doc/manual/#display-munging
> > 
> > subjectrx was added in 1.8.0, it seems.
> 
> That's wonderful! Something I've been wishing for for a long time.
> 
> But the example in the manual doesn't work for me in 1.9.3
> (on Debian testing, but I think that's back to being normal mutt,
> not neomutt, right?). This line in muttrc:
>   subjectrx '\[[^\]]*\]? *' '%L%R'
> changes
>   "Re: [LongListName] blah blah"
> to
>   "Re: ongListName] blah blah"
> 
> In other words, the first * is ignored and it matches only one
> character after the open bracket. I've tried replacing the * with
> +, with {1,} and with {0,} but none of them work: * and {1,} match
> one character while + and {1,} don't match anything and do don't
> do any substitution.
> 
> The feature is still great, because I don't strictly need the regex
> -- I can make explicit matches for the few really long list names
> that are causing problems -- but I wonder why the example in the
> manual isn't working.
> 
> Also, is it possible to escape a quote? I have one set of emails
> that come through with an apostrophe, like
>   Subject: [Don't care about this super long list ID] blah blah
> 
> Escaping within single quotes, like this:
>   subjectrx 'Don\'t care about this super long list ID]' '%LDONT%R'
> gives an "about: unknown command" error.
> 
> The workaround of using double quotes works fine:
>   subjectrx "Don't care about this super long list ID]" '%LDONT%R'
> Just curious, since the workaround is fine for now.

some time ago, in an earlier age, Sven Guckes posted a sed or perl filter
to hide "Subject:" additions, but I seem to have lost it, and he seems to
be missing too  :^(


-- 
(paka)Patrick Shanahan   Plainfield, Indiana, USA  @ptilopteri
http://en.opensuse.orgopenSUSE Community Memberfacebook/ptilopteri
Registered Linux User #207535@ http://linuxcounter.net
Photos: http://wahoo.no-ip.org/piwigo   paka @ IRCnet freenode


Re: Remove Subject prefixing (when answering/forwarding) possible?

2018-02-28 Thread Christian Ebert

* Akkana Peck on Wednesday, February 28, 2018 at 09:28:41 -0700

Todd Zullinger writes:

http://www.mutt.org/doc/manual/#display-munging

subjectrx was added in 1.8.0, it seems.


That's wonderful! Something I've been wishing for for a long time.

But the example in the manual doesn't work for me in 1.9.3
(on Debian testing, but I think that's back to being normal mutt,
not neomutt, right?). This line in muttrc:
subjectrx '\[[^\]]*\]? *' '%L%R'


I don't understand why the right bracket is backslash escaped 
inside the character group in the example.



changes
"Re: [LongListName] blah blah"
to
"Re: ongListName] blah blah"


Omitting the escape seems to work for me[tm]:

subjectrx '\[[^]]*\]:? *' '%L%R'

--
LAST SHIP HOME
Die Weltumsegelung der Peter von Danzig
Ein Film von Michael Weber und Christian Ebert
--->> https://lastshiphome.de


Re: Remove Subject prefixing (when answering/forwarding) possible?

2018-02-28 Thread Akkana Peck
Todd Zullinger writes:
> http://www.mutt.org/doc/manual/#display-munging
> 
> subjectrx was added in 1.8.0, it seems.

That's wonderful! Something I've been wishing for for a long time.

But the example in the manual doesn't work for me in 1.9.3
(on Debian testing, but I think that's back to being normal mutt,
not neomutt, right?). This line in muttrc:
  subjectrx '\[[^\]]*\]? *' '%L%R'
changes
  "Re: [LongListName] blah blah"
to
  "Re: ongListName] blah blah"

In other words, the first * is ignored and it matches only one
character after the open bracket. I've tried replacing the * with
+, with {1,} and with {0,} but none of them work: * and {1,} match
one character while + and {1,} don't match anything and do don't
do any substitution.

The feature is still great, because I don't strictly need the regex
-- I can make explicit matches for the few really long list names
that are causing problems -- but I wonder why the example in the
manual isn't working.

Also, is it possible to escape a quote? I have one set of emails
that come through with an apostrophe, like
  Subject: [Don't care about this super long list ID] blah blah

Escaping within single quotes, like this:
  subjectrx 'Don\'t care about this super long list ID]' '%LDONT%R'
gives an "about: unknown command" error.

The workaround of using double quotes works fine:
  subjectrx "Don't care about this super long list ID]" '%LDONT%R'
Just curious, since the workaround is fine for now.

...Akkana


Re: Remove Subject prefixing (when answering/forwarding) possible?

2018-02-28 Thread Sandro Santilli
On Tue, Feb 27, 2018 at 10:43:05AM -0500, Todd Zullinger wrote:

> http://www.mutt.org/doc/manual/#display-munging
> subjectrx was added in 1.8.0, it seems.

Thanks so much, I've been feeling the need for this for
a long time, finally satisfied :)

--strk;


Re: Remove Subject prefixing (when answering/forwarding) possible?

2018-02-27 Thread Cameron Simpson

On 27Feb2018 10:39, Ralf Hildebrandt <ralf.hildebra...@charite.de> wrote:

I'm using:

# Erase [ext] tags from e-mails
subjectrx '\[ext\] *' '%L%R'

to remove the tag "optically". Is there any way of removing the
Subject: prefix when answering/forwarding?


Can't speak for forwarding, but in principle you could set your editor to a 
script that preedited the compose file then ran your real editor.


My muttrc has:

 macro index g ":set editor=muttedit:set 
editor=$EDITOR" "group reply"

and "muttedit" is a personal shell script which does some stuff before finally 
invoking the editor.


Cheers,
Cameron Simpson <c...@cskk.id.au> (formerly c...@zip.com.au)


Re: Remove Subject prefixing (when answering/forwarding) possible?

2018-02-27 Thread Todd Zullinger
Matthias Apitz wrote:
> El día Tuesday, February 27, 2018 a las 10:39:53AM +0100, Ralf Hildebrandt 
> escribió:
>> I'm using:
>> 
>> # Erase [ext] tags from e-mails
>> subjectrx '\[ext\] *' '%L%R'
>> 
>> to remove the tag "optically". Is there any way of removing the
>> Subject: prefix when answering/forwarding?
> 
> How do you configure this exactly in .muttrc? Thanks

http://www.mutt.org/doc/manual/#display-munging

subjectrx was added in 1.8.0, it seems.

-- 
Todd
~~
I always keep a supply of stimulant handy in case I see a snake -
which I also keep handy.
-- W. C. Fields



signature.asc
Description: PGP signature


Re: Remove Subject prefixing (when answering/forwarding) possible?

2018-02-27 Thread Matthias Apitz
El día Tuesday, February 27, 2018 a las 10:39:53AM +0100, Ralf Hildebrandt 
escribió:

> I'm using:
> 
> # Erase [ext] tags from e-mails
> subjectrx '\[ext\] *' '%L%R'
> 
> to remove the tag "optically". Is there any way of removing the
> Subject: prefix when answering/forwarding?

How do you configure this exactly in .muttrc? Thanks

matthias
-- 
Matthias Apitz, ✉ g...@unixarea.de, ⌂ http://www.unixarea.de/   
+49-176-38902045
Public GnuPG key: http://www.unixarea.de/key.pub


Remove Subject prefixing (when answering/forwarding) possible?

2018-02-27 Thread Ralf Hildebrandt
I'm using:

# Erase [ext] tags from e-mails
subjectrx '\[ext\] *' '%L%R'

to remove the tag "optically". Is there any way of removing the
Subject: prefix when answering/forwarding?

-- 
Ralf Hildebrandt
  Geschäftsbereich IT | Abteilung Netzwerk
  Charité - Universitätsmedizin Berlin
  Campus Benjamin Franklin
  Hindenburgdamm 30 | D-12203 Berlin
  Tel. +49 30 450 570 155 | Fax: +49 30 450 570 962
  ralf.hildebra...@charite.de | https://www.charite.de


signature.asc
Description: PGP signature


Re: Clear subject field

2017-11-21 Thread Wim
Hi,

check out edit_headers and autoedit in the handbook. I'm assuming you
have a relatively new version of Mutt.

On Monday, 20 November at 12:19, Pétùr wrote:

> Hi,
> 
> Is there a way to quickly clear the subject of an email?
> 
> Right now I have to delete character by character with the del key.
> 
> I want to delete everything in the subject field and add a better
> (new) subject sometimes when forwarding email.
> 
> Pétùr

-- 
  |\  _,,,---,,_
ZZZzz /,`.-'`'-.  ;-;;,_   
 |,4-  ) )-,_. ,\ (  `'-'   
'---''(_/--'  `-'\_) 


Re: Clear subject field

2017-11-20 Thread Thomas Schneider
Pétùr:

> Is there a way to quickly clear the subject of an email?
> Right now I have to delete character by character with the del key.
> I want to delete everything in the subject field and add a better
> (new) subject sometimes when forwarding email.

I almost always jump into vim to edit the email,
so it's easy to 'd$' or edit it.

Tom

Re: Clear subject field

2017-11-20 Thread Pétùr

On Mon, Nov 20, 2017 at 08:42:28AM -0500, Ben Boeckel wrote:

On Mon, Nov 20, 2017 at 12:19:10 +0100, Pétùr wrote:

Is there a way to quickly clear the subject of an email?

Right now I have to delete character by character with the del key.

I want to delete everything in the subject field and add a better
(new) subject sometimes when forwarding email.


I use `C` in Vim to clear it and write a new one. But in the Mutt
editor/composer, there is probably support at least for `C-W` to delete
by word. I don't remember the emacs binding for line deletion. `C-K`?


Thanks C-w works to delete by word (and C-k also for the line).

Pétùr


Re: Clear subject field

2017-11-20 Thread Tom Furie
On Mon, Nov 20, 2017 at 02:18:52PM +0100, Pétùr wrote:

> I noticed also that C-k was working (but the cursor has to be at the
> beginning of the line).

Which can be achieved by C-a, in case you're interested.

Cheers,
Tom

-- 
A beginning is the time for taking the most delicate care that balances are
correct.
-- Princess Irulan, "Manual of Maud'Dib"


signature.asc
Description: Digital signature


Re: Clear subject field

2017-11-20 Thread Patrick Shanahan
* Pétùr <peturv...@gmail.com> [11-20-17 07:21]:
> Hi,
> 
> Is there a way to quickly clear the subject of an email?
> 
> Right now I have to delete character by character with the del key.
> 
> I want to delete everything in the subject field and add a better
> (new) subject sometimes when forwarding email.

look a the docs/man-page for your chosen editor. or if using mutt's
built-in, again check the docs.  mutt has some of the best documentation
available.  and of course there is always google.

 hint:  http://www.mutt.org/doc/manual/#editing

and then there is google
 
-- 
(paka)Patrick Shanahan   Plainfield, Indiana, USA  @ptilopteri
http://en.opensuse.orgopenSUSE Community Memberfacebook/ptilopteri
Registered Linux User #207535@ http://linuxcounter.net
Photos: http://wahoo.no-ip.org/piwigo   paka @ IRCnet freenode


Re: Clear subject field

2017-11-20 Thread Marcus C. Gottwald

Pétùr wrote (Mon 2017-Nov-20 12:19:10 +0100):

> Is there a way to quickly clear the subject of an email?

Pressing Ctrl+U while editing the field should do what you are
looking for.

Cheers, Marcus

-- 
   Marcus C. Gottwald  ·  <m...@cheers.de>  ·  https://cheers.de



Re: Clear subject field

2017-11-20 Thread Pétùr

On Mon, Nov 20, 2017 at 01:24:01PM +0100, Francesco Ariis wrote:

On Mon, Nov 20, 2017 at 12:19:10PM +0100, Pétùr wrote:

Hi,

Is there a way to quickly clear the subject of an email?

Right now I have to delete character by character with the del key.

I want to delete everything in the subject field and add a better
(new) subject sometimes when forwarding email.


Hi Pétùr, `C-u` does what you want. Standard bash shortcuts are
available in mutt and quite useful


Thanks!

I noticed also that C-k was working (but the cursor has to be at the
beginning of the line).

Pétùr


Re: Clear subject field

2017-11-20 Thread hymie!
Control-U ?

--hymie! http://lactose.homelinux.net/~hymiehy...@lactose.homelinux.net

On Mon, Nov 20, 2017 at 12:19:10PM +0100, Pétùr wrote:
> Hi,
> 
> Is there a way to quickly clear the subject of an email?
> 
> Right now I have to delete character by character with the del key.
> 
> I want to delete everything in the subject field and add a better
> (new) subject sometimes when forwarding email.
> 
> Pétùr


Clear subject field

2017-11-20 Thread Pétùr

Hi,

Is there a way to quickly clear the subject of an email?

Right now I have to delete character by character with the del key.

I want to delete everything in the subject field and add a better
(new) subject sometimes when forwarding email.

Pétùr


[no subject]

2016-09-28 Thread Hamish Bain
unsubscribe

-- 
Puketoi
Te Matuku Point
Waiheke Island



Re: tweak subject with regex before display

2016-01-08 Thread Grady Martin

On 2015年12月29日 17時37分, Florian Lohoff wrote:

Our companys "virus" check adds really annoying "*** unchecked ***" to
every encrypted mails subject.

Is there a way to suppress certain parts of a subject before displaying
in the folder view?


By "folder" view, do you mean "index?"  Pipe index_format's string value to a 
program or script that removes unwanted portions.  Example:

set index_format = "/path/to/script %s|"

Alternatively, mouse cords are surprisingly difficult to sever and are 
well-suited as strangling apparatus for mail administrators.  Debug the problem 
at its source and earn the trust of your coworkers.


Re: tweak subject with regex before display

2015-12-30 Thread Chris Bannister
On Tue, Dec 29, 2015 at 11:23:31AM -0800, Ian Zimmerman wrote:
> On 2015-12-29 17:37 +0100, Florian Lohoff wrote:
> 
> > Our companys "virus" check adds really annoying "*** unchecked ***" to 
> > every encrypted mails subject.
> > 
> > Is there a way to suppress certain parts of a subject before displaying
> > in the folder view?
> > 
> > To my mind comes also mailinglist tags to suppress.
> 
> Please check this thread:
> 
> http://thread.gmane.org/gmane.mail.mutt.user/43136/
> 
> tl;dr

Is it really that long that you didn't read it? (I think people abuse
tl;dr.)

:)

-- 
"If you're not careful, the newspapers will have you hating the people
who are being oppressed, and loving the people who are doing the 
oppressing." --- Malcolm X


tweak subject with regex before display

2015-12-29 Thread Florian Lohoff

Hi,

Our companys "virus" check adds really annoying "*** unchecked ***" to 
every encrypted mails subject.

Is there a way to suppress certain parts of a subject before displaying
in the folder view?

To my mind comes also mailinglist tags to suppress.

Flo
-- 
Florian Lohoff f...@zz.de
  We need to self-defend - GnuPG/PGP enable your email today!


signature.asc
Description: Digital signature


Re: tweak subject with regex before display

2015-12-29 Thread Ian Zimmerman
On 2015-12-29 17:37 +0100, Florian Lohoff wrote:

> Our companys "virus" check adds really annoying "*** unchecked ***" to 
> every encrypted mails subject.
> 
> Is there a way to suppress certain parts of a subject before displaying
> in the folder view?
> 
> To my mind comes also mailinglist tags to suppress.

Please check this thread:

http://thread.gmane.org/gmane.mail.mutt.user/43136/

tl;dr

People do that outside of mutt, with procmail and similar tools.

-- 
Please *no* private copies of mailing list or newsgroup messages.
Rule 420: All persons more than eight miles high to leave the court.


Re: Default send subject for group

2015-10-18 Thread Francesco Ariis
On Sun, Oct 18, 2015 at 02:49:27PM +0200, Teon Banek wrote:
> Hello everyone,
> 
> Is it possible to have a default subject prefix when sending a mail to a
> group? For example, I have a group of people and I'd like to
> automatically fill in the subject with '[Group]' when sending mail to
> all members of the group. Basically, what I want is subject prefix
> functionality of gmail.
> 
> As far as I can tell (and is mentioned in manual), modifying subject
> header through `my_hdr` variable isn't supported in `send-hook`.
> 
> Also, what are the differences between having an alias with multiple
> people and creating a group?

Would using a macro be a viable choice?


Default send subject for group

2015-10-18 Thread Teon Banek
Hello everyone,

Is it possible to have a default subject prefix when sending a mail to a
group? For example, I have a group of people and I'd like to
automatically fill in the subject with '[Group]' when sending mail to
all members of the group. Basically, what I want is subject prefix
functionality of gmail.

As far as I can tell (and is mentioned in manual), modifying subject
header through `my_hdr` variable isn't supported in `send-hook`.

Also, what are the differences between having an alias with multiple
people and creating a group?

Thanks!

-- 
Teon Banek


Re: Default send subject for group

2015-10-18 Thread Teon Banek
On Sun, Oct 18, 2015 at 02:59:38PM +0200, Francesco Ariis wrote:
> On Sun, Oct 18, 2015 at 02:49:27PM +0200, Teon Banek wrote:
> > Hello everyone,
> > 
> > Is it possible to have a default subject prefix when sending a mail to a
> > group? For example, I have a group of people and I'd like to
> > automatically fill in the subject with '[Group]' when sending mail to
> > all members of the group. Basically, what I want is subject prefix
> > functionality of gmail.
> > 
> > As far as I can tell (and is mentioned in manual), modifying subject
> > header through `my_hdr` variable isn't supported in `send-hook`.
> > 
> > Also, what are the differences between having an alias with multiple
> > people and creating a group?
> 
> Would using a macro be a viable choice?

It would, since I don't have many groups nor any macros at the moment.
I would prefer a solution akin to a hook, though.

-- 
Teon Banek


(no subject)

2015-06-15 Thread Staffan Thomén

unsubscribe


Re: (no subject)

2015-06-15 Thread Matthias Apitz
El día Monday, June 15, 2015 a las 07:45:02PM +0300, Staffan Thomén escribió:

 unsubscribe

No! I will not unsubscribe me.

-- 
Matthias Apitz, g...@unixarea.de, http://www.unixarea.de/ +49-170-4527211
+49-176-38902045
Wenn der Mensch von den Umständen gebildet wird, so muß man die Umstände 
menschlich bilden.
Si el hombre es formado por las circunstancias entonces es necesario formar 
humanamente
las circunstancias, Karl Marx in Die heilige Familie / La sagrada familia (MEW 
2, 138)


Re: (no subject)

2015-06-15 Thread Артур Истомин
On Mon, Jun 15, 2015 at 07:45:02PM +0300, Staffan Thomén wrote:
 unsubscribe

Come on, Staffan! Where are you going?!
 


Re: (no subject)

2015-06-15 Thread Patrick Shanahan
* Артур Истомин art.is...@yandex.ru [06-15-15 15:34]:
 On Mon, Jun 15, 2015 at 07:45:02PM +0300, Staffan Thomén wrote:
  unsubscribe
 
 Come on, Staffan! Where are you going?!

Well, if he can't figure it out, probably has no business with mutt :) 
doah
-- 
(paka)Patrick Shanahan   Plainfield, Indiana, USA  @ptilopteri
http://en.opensuse.orgopenSUSE Community Memberfacebook/ptilopteri
http://wahoo.no-ip.orgPhoto Album: http://wahoo.no-ip.org/gallery2
Registered Linux User #207535@ http://linuxcounter.net


Re: Disable To/Cc/Subject prompts when replying, but not when creating

2014-07-15 Thread Christian Ebert
* Chris Down on Tuesday, July 15, 2014 at 11:45:26 +0800
 Is there some way to disable the prompts for To/Cc/Subject when replying
 to a message, but still have them appear when creating a new one?

Try:

set fast_reply=yes

-- 
theatre - books - texts - movies
Black Trash Productions at home: http://www.blacktrash.org
Black Trash Productions on Facebook:
http://www.facebook.com/blacktrashproductions


Disable To/Cc/Subject prompts when replying, but not when creating

2014-07-14 Thread Chris Down
Hello,

Is there some way to disable the prompts for To/Cc/Subject when replying
to a message, but still have them appear when creating a new one?

Thanks. :-)


[no subject]

2014-06-21 Thread Elimar Riesebieter
* Martin Vegter martin.veg...@aol.com [2014-06-19 14:56 +0200]:

 Hello,
 when I pres s to save an attachment (i.e. foo.pdf), Mutt asks me:
 
 Save to file: foo.pdf
 
 Is there a way to prepend ~/tmp/ in front of the name, so that by
 default all files are saved in ~/tmp/? Basically, I would like mutt to

After pressing s just type tab to choose the dir / filename you
want to save to.

Elimar
-- 
 We all know Linux is great... it does infinite loops in 5 seconds.
-Linus Torvalds


[no subject]

2014-05-08 Thread Shawn Zaidermann

approve 48zvVL unsubscribe mutt-dev shawnzaiderm...@gmail.com


Re: inconsistent display of subject line

2013-10-21 Thread Michael Elkins

How can I fix the descibed behavior?


Did you link Mutt with with libncursesw (the wide-char version)?  
This can happen when you link against libncurses instead.

--
PGP key 4096R/4054DBFA DD1E A7F4 7860 2D5E 7BDE  459E DB99 9B42 4054 DBFA


Re: inconsistent display of subject line

2013-10-21 Thread Michael Elkins

On Tue, Oct 22, 2013 at 01:43:04AM +0200, Ulrich Lauther wrote:

On Mon, Oct 21, 2013 at 09:02:22PM +, Michael Elkins wrote:

How can I fix the descibed behavior?

Did you link Mutt with with libncursesw (the wide-char version)?  This can
happen when you link against libncurses instead.


Yes, changing in the Makefile the MUTTLIBS line to
   MUTTLIBS =  /lib/i386-linux-gnu/libncursesw.so.5
helps.

However,
   MUTTLIBS =  -L/lib/i386-linux-gnu -lncursesw
gives
   /usr/bin/ld: cannot find -lncursesw

Why?


Make sure you have installed the libncursesw5-dev package.
--
PGP key 4096R/4054DBFA DD1E A7F4 7860 2D5E 7BDE  459E DB99 9B42 4054 DBFA


  1   2   3   4   5   >