sup

A curses threads-with-tags style email client

sup.git

git clone https://supmua.dev/git/sup/
commit 4204170b7a52847c6d14e799123dd9681f75e11c
parent cd8441837c5cd16cc35b951d96415a0f80671fe2
Author: Dan Callaghan <djc@djc.id.au>
Date:   Sun, 12 Jul 2020 18:06:14 +1000

don't monkey-patch RMail::Header::Field#parse

This was fixed in rmail 1.1.2:
https://github.com/terceiro/rmail/commit/0479219aec5562735526001cfe16723d3b920ed2

Diffstat:
M lib/sup/util.rb | 17 -----------------
M sup.gemspec | 2 +-
2 files changed, 1 insertion(+), 18 deletions(-)
diff --git a/lib/sup/util.rb b/lib/sup/util.rb
@@ -120,23 +120,6 @@ module RMail
   end
 
   class Header
-
-    # Convert to ASCII before trying to match with regexp
-    class Field
-
-      class << self
-        def parse(field)
-          field = field.dup.to_s
-          field = field.fix_encoding!.ascii
-          if field =~ EXTRACT_FIELD_NAME_RE
-            [ $1, $'.chomp ]
-          else
-            [ "", Field.value_strip(field) ]
-          end
-        end
-      end
-    end
-
     ## Be more cautious about invalid content-type headers
     ## the original RMail code calls
     ## value.strip.split(/\s*;\s*/)[0].downcase
diff --git a/sup.gemspec b/sup.gemspec
@@ -51,7 +51,7 @@ SUP: please note that our old mailing lists have been shut down,
   ## ext/mkrf_conf_xapian.rb and Gemfile.
 
   s.add_runtime_dependency "ncursesw", "~> 1.4.0"
-  s.add_runtime_dependency "rmail", "~> 1.1"
+  s.add_runtime_dependency "rmail", ">= 1.1.2", "< 2"
   s.add_runtime_dependency "highline"
   s.add_runtime_dependency "optimist"
   s.add_runtime_dependency "lockfile"