* bug#34654: Attaching a file with a new name in a message
@ 2019-02-25 18:42 Abdo Haji-Ali
2019-03-31 1:23 ` Federico Tedin
2019-05-13 20:13 ` Lars Ingebrigtsen
0 siblings, 2 replies; 3+ messages in thread
From: Abdo Haji-Ali @ 2019-02-25 18:42 UTC (permalink / raw)
To: 34654
Hello,
I am using Emacs 26.1 to send my emails. While writing an email, I
attach files by calling
`mail-attach-file` (bound to C-c C-a on my setup)
I usually want to rename the file before sending so that my local file
name doesn't appear to the recipient. I found in the docs that setting
the properties 'recipient-filename' or 'name' in the <part> tag should
do the trick. However, this doesn't seem to be the case, since my
recipients are still receiving files with my original filenames.
Looking at the raw message I found in the header
Content-Disposition: attachment; filename="old-name.pdf"
Even when I set the 'recipient-filename' and 'name' properties.
Looking through the source, it seems that line 904 in mml.el always
sets the Content-Disposition filename to the original filename,
disregarding the 'recipient-filename' and 'name' properties.
Is this intentional? Is there another to achieve what I want?
^ permalink raw reply [flat|nested] 3+ messages in thread
* bug#34654: Attaching a file with a new name in a message
2019-02-25 18:42 bug#34654: Attaching a file with a new name in a message Abdo Haji-Ali
@ 2019-03-31 1:23 ` Federico Tedin
2019-05-13 20:13 ` Lars Ingebrigtsen
1 sibling, 0 replies; 3+ messages in thread
From: Federico Tedin @ 2019-03-31 1:23 UTC (permalink / raw)
To: Abdo Haji-Ali; +Cc: 34654
Abdo Haji-Ali <abdo.haji.ali@gmail.com> writes:
> Hello,
>
> I am using Emacs 26.1 to send my emails. While writing an email, I
> attach files by calling
> `mail-attach-file` (bound to C-c C-a on my setup)
> I usually want to rename the file before sending so that my local file
> name doesn't appear to the recipient. I found in the docs that setting
> the properties 'recipient-filename' or 'name' in the <part> tag should
> do the trick. However, this doesn't seem to be the case, since my
> recipients are still receiving files with my original filenames.
> Looking at the raw message I found in the header
>
> Content-Disposition: attachment; filename="old-name.pdf"
>
> Even when I set the 'recipient-filename' and 'name' properties.
> Looking through the source, it seems that line 904 in mml.el always
> sets the Content-Disposition filename to the original filename,
> disregarding the 'recipient-filename' and 'name' properties.
>
> Is this intentional? Is there another to achieve what I want?
Adding 'recipient-filename to mml-content-disposition-parameters makes
future messages include the property in the "Content-Disposition"
header. However, the "filename" property is still sent, and my email
client (GMail) uses "filename" and not "recipient-filename" to display
the attachment file name. Maybe Emacs should replace the contents of
"filename" with the ones of "recipient-filename"?
^ permalink raw reply [flat|nested] 3+ messages in thread
* bug#34654: Attaching a file with a new name in a message
2019-02-25 18:42 bug#34654: Attaching a file with a new name in a message Abdo Haji-Ali
2019-03-31 1:23 ` Federico Tedin
@ 2019-05-13 20:13 ` Lars Ingebrigtsen
1 sibling, 0 replies; 3+ messages in thread
From: Lars Ingebrigtsen @ 2019-05-13 20:13 UTC (permalink / raw)
To: Abdo Haji-Ali; +Cc: 34654
Abdo Haji-Ali <abdo.haji.ali@gmail.com> writes:
> Content-Disposition: attachment; filename="old-name.pdf"
>
> Even when I set the 'recipient-filename' and 'name' properties.
> Looking through the source, it seems that line 904 in mml.el always
> sets the Content-Disposition filename to the original filename,
> disregarding the 'recipient-filename' and 'name' properties.
>
> Is this intentional? Is there another to achieve what I want?
It looks like the documented recipient-filename functionality was never
actually implemented? I grepped through the sources for
"recipient-filename" and found nothing. Weird.
Anyway, I've now added the functionality to Emacs 27.1.
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2019-05-13 20:13 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-02-25 18:42 bug#34654: Attaching a file with a new name in a message Abdo Haji-Ali
2019-03-31 1:23 ` Federico Tedin
2019-05-13 20:13 ` Lars Ingebrigtsen
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).