From: Sean Whitton <spwhitton@spwhitton.name>
To: Philip Kaludercic <philipk@posteo.net>
Cc: 60147@debbugs.gnu.org
Subject: bug#60147: 30.0.50; vc-prepare-patch: Add numbered patch file names
Date: Sat, 17 Dec 2022 17:33:30 -0700 [thread overview]
Message-ID: <87r0wxv9d1.fsf@melete.silentflame.com> (raw)
In-Reply-To: <87y1r64bof.fsf@posteo.net> (Philip Kaludercic's message of "Sat, 17 Dec 2022 09:33:20 +0000")
Hello,
On Sat 17 Dec 2022 at 09:33AM GMT, Philip Kaludercic wrote:
>> + (filename
>> + (concat
>> + (string-trim
>> + (replace-regexp-in-string
>> + "\\W" "-" (if (length> stripped-subject 50)
>> + (substring stripped-subject 0 50)
>> + stripped-subject))
>
> Is limiting the file names to ~50 characters a Git thing?
Git does it, yes, and I thought it seemed like a good idea in general.
>> + (mml-attach-buffer
>> + (buffer-name (plist-get patch :buffer))
>> + "text/x-patch"
>> + patch-subject
>> + "attachment"
>> + (format "%04d-%s" (cl-incf i) filename))))))
>
> Is the new additional argument really necessary, or couldn't we just
> rename the generated buffer? We could specify that the buffer must be
> fresh/renameable.
The description and the filename for an attachment are not the same
thing -- I don't believe MUAs will save the files with the correct name
unless there is the filename= field. And I think it's a useful general
addition to mml-attach-buffer.
--
Sean Whitton
next prev parent reply other threads:[~2022-12-18 0:33 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-12-17 5:40 bug#60147: 30.0.50; vc-prepare-patch: Add numbered patch file names Sean Whitton
2022-12-17 9:33 ` Philip Kaludercic
2022-12-18 0:33 ` Sean Whitton [this message]
2022-12-18 10:45 ` Philip Kaludercic
2022-12-20 0:17 ` Sean Whitton
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87r0wxv9d1.fsf@melete.silentflame.com \
--to=spwhitton@spwhitton.name \
--cc=60147@debbugs.gnu.org \
--cc=philipk@posteo.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).