From 48f9118253859969d0f300dcb13b84a99c2f5bd4 Mon Sep 17 00:00:00 2001 From: nobu Date: Thu, 6 Oct 2016 02:01:51 +0000 Subject: [PATCH] Update URI WEB_ENCODINGS_ hash, and fix documented cmd to git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@56356 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ChangeLog | 4 ++++ lib/uri/common.rb | 4 +++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 08d11c9400..786cb5808a 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +Thu Oct 6 11:01:49 2016 Tieg Zaharia + + + Thu Oct 6 10:37:13 2016 SHIBATA Hiroshi * enum.c: Add reduce/inject alias note. diff --git a/lib/uri/common.rb b/lib/uri/common.rb index 4c7d112e61..a6ca3365a7 100644 --- a/lib/uri/common.rb +++ b/lib/uri/common.rb @@ -487,7 +487,7 @@ module URI end private - # curl http://encoding.spec.whatwg.org/encodings.json|rb -rpp -rjson -e'H={};h={"shift_jis"=>"Windows-31J","euc-jp"=>"cp51932","iso-2022-jp"=>"cp50221","x-mac-cyrillic"=>"macCyrillic"};JSON($<.read).map{|x|x["encodings"]}.flatten.each{|x|Encoding.find(n=h.fetch(n=x["name"],n))rescue next;x["labels"].each{|y|H[y]=n}};pp H' + # curl https://encoding.spec.whatwg.org/encodings.json|ruby -rpp -rjson -e'H={};h={"shift_jis"=>"Windows-31J","euc-jp"=>"cp51932","iso-2022-jp"=>"cp50221","x-mac-cyrillic"=>"macCyrillic"};JSON($<.read).map{|x|x["encodings"]}.flatten.each{|x|Encoding.find(n=h.fetch(n=x["name"].downcase,n))rescue next;x["labels"].each{|y|H[y]=n}};pp H' WEB_ENCODINGS_ = { "unicode-1-1-utf-8"=>"utf-8", "utf-8"=>"utf-8", @@ -593,6 +593,7 @@ module URI "koi8"=>"koi8-r", "koi8-r"=>"koi8-r", "koi8_r"=>"koi8-r", + "koi8-ru"=>"koi8-u", "koi8-u"=>"koi8-u", "dos-874"=>"windows-874", "iso-8859-11"=>"windows-874", @@ -673,6 +674,7 @@ module URI "csiso2022jp"=>"cp50221", "iso-2022-jp"=>"cp50221", "csshiftjis"=>"Windows-31J", + "ms932"=>"Windows-31J", "ms_kanji"=>"Windows-31J", "shift-jis"=>"Windows-31J", "shift_jis"=>"Windows-31J",