Subject: [PATCH] Fix submit-emacs-patch MIME type
From: Steven Allen <[email-masked]>
To: [email-masked]
Date: Thu, 21 Aug 2025 11:23:40 -0700
List-Id: <debbugs-submit.debbugs.gnu.org>

Tags: patch

Change from text/patch to text/x-patch.

In GNU Emacs 31.0.50 (build 3, x86_64-pc-linux-gnu, cairo version
 1.18.4) of 2025-08-21 built on Laptop
Repository revision: 32b65fefb61426d76c9c899dbd3e4a1b8ed774b2
Repository branch: merged
Windowing system distributor 'The X.Org Foundation', version 11.0.12101018
System Description: Arch Linux

Configured using:
 'configure
 'CPPFLAGS=-I/run/user/1000/build/emacs-git/src/mps-git/build/include '
 'LDFLAGS=-L/run/user/1000/build/emacs-git/src/mps-git/build/lib -Wl,-O1
 -Wl,--sort-common -Wl,--as-needed -Wl,-z,relro -Wl,-z,now
 -Wl,-z,pack-relative-relocs -flto=auto' --prefix=/usr --sysconfdir=/etc
 --libexecdir=/usr/lib --localstatedir=/var --mandir=/usr/share/man
 --with-gameuser=:games --with-modules --without-m17n-flt
 --without-selinux --without-pop --without-gconf --disable-gc-mark-trace
 --with-mps=yes --enable-link-time-optimization
 --with-native-compilation=yes --with-xinput2 --with-x-toolkit=no
 --without-toolkit-scroll-bars --without-xaw3d --without-gsettings
 --with-cairo-xcb --without-xft --with-sound=no --with-tree-sitter
 --without-gpm --without-compress-install
 '--program-transform-name=s/\([ec]tags\)/\1.emacs/'
 'CFLAGS=-march=native -mtune=native -O3 -pipe -fno-plt -fexceptions
 -Wp,-D_FORTIFY_SOURCE=3 -Wformat -Werror=format-security
 -fstack-clash-protection -fcf-protection -fomit-frame-pointer
 -fno-math-errno -fno-trapping-math -fno-math-errno -fno-trapping-math
 -flto=auto' 'CXXFLAGS=-march=native -mtune=native -O3 -pipe -fno-plt
 -fexceptions -Wp,-D_FORTIFY_SOURCE=3 -Wformat -Werror=format-security
 -fstack-clash-protection -fcf-protection -fomit-frame-pointer
 -Wp,-D_GLIBCXX_ASSERTIONS -flto=auto''

From ada1f311b7917709ea370d37ae9a21eb11913189 Mon Sep 17 00:00:00 2001
From: Steven Allen <[email-masked]>
Date: Thu, 21 Aug 2025 11:15:02 -0700
Subject: [PATCH] Fix submit-emacs-patch MIME type

The correct MIME type is text/x-patch. Otherwise,
`mm-inline-media-tests' won't recognize and fontify the patch.

* lisp/mail/emacsbug.el (submit-emacs-patch): Use the correct MIME type
for patches.
---
 lisp/mail/emacsbug.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lisp/mail/emacsbug.el b/lisp/mail/emacsbug.el
index d43647a12ca..4872f721aa5 100644
--- a/lisp/mail/emacsbug.el
+++ b/lisp/mail/emacsbug.el
@@ -587,7 +587,7 @@ submit-emacs-patch
   (message-goto-body)
   (insert "\n\n\n")
   (emacs-build-description)
-  (mml-attach-file file "text/patch" nil "attachment")
+  (mml-attach-file file "text/x-patch" nil "attachment")
   (message-goto-body)
   (message "Write a description of the patch and use %s to send it"
            (substitute-command-keys "\\[message-send-and-exit]"))
-- 
2.50.1