Re: [exmh-workers] Aging Dependencies?

Kevin Cosgrove <[email protected]> Sun, 06 May 2012 11:55:30 -0700
Newsgroups gmane.mail.exmh.user,gmane.mail.exmh.devel
Message-ID <[email protected]>
On 6 May 2012 at 15:10, "Welch, Brent" <[email protected]> wrote:

> The mangle patch changes a . to a [^\n] in regexp, which seems
> pretty good.  I gather you don't want to gobble up the whole
> message when we're matching "BEGIN PGP MESSAGE" and that line
> is messed up.

Maybe that one will make it into 2.8.1.

There's another simple patch attached.  This one makes gvim's
syntax highlighting happy, just by removing a space in the code.

> The other patch drops a ";" from the mail headers, and I'm not
> sure that's ok ? It also changes the mime type to text/x-pgp
> from text/pgp - not sure that is what you want either ?

Your comment nudged me into refactoring my patches.  Now all of
my PGP related stuff is in the attached pgptext.patch file.  It's
been 10 years since I adopted that mess, and I can't recall what
I wanted to change, nor even whether those patches are authored
by me.  But, I can say that my GPG interactions with exmh are
pleasant.

> I do plan to make a 2.8.1 after we flush out more patches like
> this that folks have been carrying around.

I was thinking I read that intent in this thread.

Thanks!

--
Kevin

_______________________________________________
Exmh-users mailing list
[email protected]
https://www.redhat.com/mailman/listinfo/exmh-users
exmh-2.8.0-vimsyntax.patch (application/x-patch, 415 B)
diff -uNr exmh-2.8.0-cvs-2012-05-02-conf/inc.expect exmh-2.8.0-cvs-2012-05-02/inc.expect
--- exmh-2.8.0-cvs-2012-05-02-conf/inc.expect	2012-05-05 23:26:56.807014778 -0700
+++ exmh-2.8.0-cvs-2012-05-02/inc.expect	2012-05-05 23:48:58.581832908 -0700
@@ -67,7 +67,7 @@
         }
 
         eof {
-	    if { [lindex [wait] 3] == 0 } {
+	    if{ [lindex [wait] 3] == 0 } {
 		exit 0
 	    } else {
 		send_user $incout
exmh-2.8.0-pgptext.patch (application/x-patch, 2.9 KB)
diff -uNr exmh-2.8.0-cvs-2012-05-02-cosgroves/lib/pgpMain.tcl exmh-2.8.0-cvs-2012-05-02/lib/pgpMain.tcl
--- exmh-2.8.0-cvs-2012-05-02-cosgroves/lib/pgpMain.tcl	2011-12-06 18:08:42.000000000 -0800
+++ exmh-2.8.0-cvs-2012-05-02/lib/pgpMain.tcl	2012-05-06 00:06:27.693201246 -0700
@@ -476,7 +476,7 @@
 	ExmhLog "<Pgp_Process> Encrypting with public key(s): [join $ids ", "]"
 
 	if {$pgp(format,$id) == "app"} {
-	    append typeparams ";\n\tx-recipients=\"[join [Pgp_Misc_Map key {string range [lindex $key 0] 2 end} $ids] ", "]\""
+	    append typeparams "\n\tx-recipients=\"[join [Pgp_Misc_Map key {string range [lindex $key 0] 2 end} $ids] ", "]\""
 	}
     }
       
@@ -580,7 +580,7 @@
 
     lappend mailheaders \
                 "mime-version: 1.0" \
-                "content-type: application/pgp; format=mime$typeparams" \
+                "content-type: application/x-pgp; format=mime$typeparams" \
                 "content-transfer-encoding: 7bit"
 
     # write out the new mail file
@@ -712,7 +712,7 @@
 	    # -----BEGIN PGP SIGNED MESSAGE-----
 	    # Hash: SHA1
 	    #####
-	    set a [regsub "^(-----BEGIN.+MESSAGE-----\n)(\[^ \n\t:\]+: \[^\n\]+\n)?((\[^ :\t\n]+\[ \t]*)+\n)" $pgptext "\\1\\2\n\\3" pgptext]
+	    set a [regsub "^(-----BEGIN\[^\n]+MESSAGE-----\n)(\[^ \n\t:\]+: \[^\n\]+\n)?((\[^ :\t\n]+\[ \t]*)+\n)" $pgptext "\\1\\2\n\\3" pgptext]
 	    #####
 	    # Blank line after
 	    # -----BEGIN PGP SIGNATURE-----
@@ -720,7 +720,7 @@
 	    # Charset: noconv
 	    # ...    : ...
 	    #####
-	    set b [regsub "(-----BEGIN.+SIGNATURE-----\n)((\[^ \n\t:\]+: \[^\n\]+\n)+)((\[^ :\t\n]+\[ \t]*)+\n)" $pgptext "\\1\\2\n\\4" pgptext]
+	    set b [regsub "^(-----BEGIN\[^\n]+SIGNATURE-----\n)((\[^ \n\t:\]+: \[^\n\]+\n)+)((\[^ :\t\n]+\[ \t]*)+\n)" $pgptext "\\1\\2\n\\4" pgptext]
 	    Exmh_Debug "<Pgp_CheckBlankLines> Number of blank lines added: $a-$b"
 	    }
 	{BEGIN PGP MESSAGE} {
diff -uNr exmh-2.8.0-cvs-2012-05-02-cosgroves/lib/app-defaults exmh-2.8.0-cvs-2012-05-02/lib/app-defaults
--- exmh-2.8.0-cvs-2012-05-02-cosgroves/lib/app-defaults	2011-04-23 20:44:48.000000000 -0700
+++ exmh-2.8.0-cvs-2012-05-02/lib/app-defaults	2012-05-06 00:03:04.874935368 -0700
@@ -947,7 +947,7 @@
 *Sedit.Menubar.pgp.m.format.t_plain:	radio
 *Sedit.Menubar.pgp.m.format.v_plain:	pgp(format,$id)
 *Sedit.Menubar.pgp.m.format.x_plain:	plain
-*Sedit.Menubar.pgp.m.format.l_app:	Application/PGP
+*Sedit.Menubar.pgp.m.format.l_app:	Text/PGP
 *Sedit.Menubar.pgp.m.format.t_app:	radio
 *Sedit.Menubar.pgp.m.format.v_app:	pgp(format,$id)
 *Sedit.Menubar.pgp.m.format.x_app:	app
@@ -1177,7 +1177,7 @@
 *WhatNow.more.m.encrypt.format.t_plain:	radio
 *WhatNow.more.m.encrypt.format.v_plain:	pgp(format,$id)
 *WhatNow.more.m.encrypt.format.x_plain:	plain
-*WhatNow.more.m.encrypt.format.l_app:	Application/PGP
+*WhatNow.more.m.encrypt.format.l_app:	Text/PGP
 *WhatNow.more.m.encrypt.format.t_app:	radio
 *WhatNow.more.m.encrypt.format.v_app:	pgp(format,$id)
 *WhatNow.more.m.encrypt.format.x_app:	app