ruby-changes:58616
From: Hiroshi <ko1@a...>
Date: Thu, 7 Nov 2019 17:02:58 +0900 (JST)
Subject: [ruby-changes:58616] 223d3c460a (master): Promote net-smtp to default gems
https://git.ruby-lang.org/ruby.git/commit/?id=223d3c460a From 223d3c460a25e47577b6414e3ed141e54864c8dd Mon Sep 17 00:00:00 2001 From: Hiroshi SHIBATA <hsbt@r...> Date: Thu, 7 Nov 2019 15:38:40 +0900 Subject: Promote net-smtp to default gems diff --git a/doc/maintainers.rdoc b/doc/maintainers.rdoc index 888a936..64089cc 100644 --- a/doc/maintainers.rdoc +++ b/doc/maintainers.rdoc @@ -66,8 +66,6 @@ Zachary Scott (zzak) https://github.com/ruby/ruby/blob/trunk/doc/maintainers.rdoc#L66 NARUSE, Yui (naruse) [lib/net/protocol.rb] _unmaintained_ -[lib/net/smtp.rb] - _unmaintained_ [lib/observer.rb] _unmaintained_ [lib/open-uri.rb] @@ -211,6 +209,10 @@ Zachary Scott (zzak) https://github.com/ruby/ruby/blob/trunk/doc/maintainers.rdoc#L209 _unmaintained_ https://github.com/ruby/net-pop https://rubygems.org/gems/net-pop +[lib/net/smtp.rb] + _unmaintained_ + https://github.com/ruby/net-smtp + https://rubygems.org/gems/net-smtp [lib/open3.rb] _unmaintained_ https://github.com/ruby/open3 diff --git a/doc/standard_library.rdoc b/doc/standard_library.rdoc index 3976d0f..b6b0eb4 100644 --- a/doc/standard_library.rdoc +++ b/doc/standard_library.rdoc @@ -21,7 +21,6 @@ Monitor:: Provides an object or module to use safely by more than one thread https://github.com/ruby/ruby/blob/trunk/doc/standard_library.rdoc#L21 Net::FTP:: Support for the File Transfer Protocol Net::HTTP:: HTTP client api for Ruby Net::IMAP:: Ruby client api for Internet Message Access Protocol -Net::SMTP:: Simple Mail Transfer Protocol client library for Ruby Observable:: Provides a mechanism for publish/subscribe pattern in Ruby OpenURI:: An easy-to-use wrapper for Net::HTTP, Net::HTTPS and Net::FTP OptionParser:: Ruby-oriented class for command-line option analysis @@ -78,6 +77,7 @@ Logger:: Provides a simple logging utility for outputting messages https://github.com/ruby/ruby/blob/trunk/doc/standard_library.rdoc#L77 Matrix:: Represents a mathematical matrix. Mutex_m:: Mixin to extend objects to be handled like a Mutex Net::POP3:: Ruby client library for POP3 +Net::SMTP:: Simple Mail Transfer Protocol client library for Ruby Open3:: Provides access to stdin, stdout and stderr when running other programs OpenStruct:: Class to build custom data structures, similar to a Hash Prime:: Prime numbers and factorization library diff --git a/lib/net/smtp.rb b/lib/net/smtp.rb index 56600a0..8e10dc2 100644 --- a/lib/net/smtp.rb +++ b/lib/net/smtp.rb @@ -17,7 +17,7 @@ https://github.com/ruby/ruby/blob/trunk/lib/net/smtp.rb#L17 # See Net::SMTP for documentation. # -require_relative 'protocol' +require 'net/protocol' require 'digest/md5' require 'timeout' begin diff --git a/lib/net/smtp/net-smtp.gemspec b/lib/net/smtp/net-smtp.gemspec new file mode 100644 index 0000000..e9635cd --- /dev/null +++ b/lib/net/smtp/net-smtp.gemspec @@ -0,0 +1,27 @@ https://github.com/ruby/ruby/blob/trunk/lib/net/smtp/net-smtp.gemspec#L1 +begin + require_relative "lib/net/smtp/version" +rescue LoadError # Fallback to load version file in ruby core repository + require_relative "version" +end + +Gem::Specification.new do |spec| + spec.name = "net-smtp" + spec.version = Net::SMTP::VERSION + spec.authors = ["Yukihiro Matsumoto"] + spec.email = ["matz@r..."] + + spec.summary = %q{Simple Mail Transfer Protocol client library for Ruby.} + spec.description = %q{Simple Mail Transfer Protocol client library for Ruby.} + spec.homepage = "https://github.com/ruby/net-smtp" + spec.license = "BSD-2-Clause" + + spec.metadata["homepage_uri"] = spec.homepage + spec.metadata["source_code_uri"] = spec.homepage + + spec.files = Dir.chdir(File.expand_path('..', __FILE__)) do + `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) } + end + spec.bindir = "exe" + spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) } + spec.require_paths = ["lib"] +end diff --git a/lib/net/smtp/version.rb b/lib/net/smtp/version.rb new file mode 100644 index 0000000..86c4ed1 --- /dev/null +++ b/lib/net/smtp/version.rb @@ -0,0 +1,5 @@ https://github.com/ruby/ruby/blob/trunk/lib/net/smtp/version.rb#L1 +module Net + module SMTP + VERSION = "0.1.0" + end +end diff --git a/tool/sync_default_gems.rb b/tool/sync_default_gems.rb index 7554358..5f5825e 100644 --- a/tool/sync_default_gems.rb +++ b/tool/sync_default_gems.rb @@ -40,6 +40,7 @@ https://github.com/ruby/ruby/blob/trunk/tool/sync_default_gems.rb#L40 # * https://github.com/ruby/delegate # * https://github.com/ruby/benchmark # * https://github.com/ruby/net-pop +# * https://github.com/ruby/net-smtp # require 'fileutils' @@ -87,6 +88,7 @@ $repositories = { https://github.com/ruby/ruby/blob/trunk/tool/sync_default_gems.rb#L88 delegate: "ruby/delegate", benchmark: "ruby/benchmark", netpop: "ruby/net-pop", + netsmtp: "ruby/net-smtp", } def sync_default_gems(gem) @@ -227,6 +229,9 @@ def sync_default_gems(gem) https://github.com/ruby/ruby/blob/trunk/tool/sync_default_gems.rb#L229 when "netpop" sync_lib "net-pop" mv "lib/net-pop.gemspec", "lib/net/pop" + when "netsmtp" + sync_lib "net-smtp" + mv "lib/net-smtp.gemspec", "lib/net/smtp" else sync_lib gem end -- cgit v0.10.2 -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/