diff --git a/lib/net/smtp.rb b/lib/net/smtp.rb index 6ceb61b..8510d36 100644 --- a/lib/net/smtp.rb +++ b/lib/net/smtp.rb @@ -79,11 +79,11 @@ class SMTPUnsupportedCommand < ProtocolError # == What is This Library? # # This library provides functionality to send internet - # mail via SMTP, the Simple Mail Transfer Protocol. For details of - # SMTP itself, see [RFC5321] (http://www.ietf.org/rfc/rfc5321.txt). - # This library also implements SMTP authentication, which is often + # mail via \SMTP, the Simple Mail Transfer Protocol. For details of + # \SMTP itself, see [RFC5321] (http://www.ietf.org/rfc/rfc5321.txt). + # This library also implements \SMTP authentication, which is often # necessary for message composers to submit messages to their - # outgoing SMTP server, see + # outgoing \SMTP server, see # [RFC6409](http://www.ietf.org/rfc/rfc6503.txt), # and [SMTPUTF8](http://www.ietf.org/rfc/rfc6531.txt), which is # necessary to send messages to/from addresses containing characters @@ -147,7 +147,7 @@ class SMTPUnsupportedCommand < ProtocolError # smtp.send_message msgstr, 'from@address', 'to@address' # smtp.finish # - # You can also use the block form of SMTP.start/SMTP#start. This closes + # You can also use the block form of SMTP.start or SMTP#start. This closes # the SMTP session automatically: # # # using block form of SMTP.start @@ -160,30 +160,31 @@ class SMTPUnsupportedCommand < ProtocolError # === HELO domain # # In almost all situations, you must provide a third argument - # to SMTP.start/SMTP#start. This is the domain name which you are on + # to SMTP.start or SMTP#start. This is the domain name which you are on # (the host to send mail from). It is called the "HELO domain". # The SMTP server will judge whether it should send or reject # the SMTP session by inspecting the HELO domain. # - # Net::SMTP.start('your.smtp.server', 25 - # helo: 'mail.from.domain') { |smtp| ... } + # Net::SMTP.start('your.smtp.server', 25, helo: 'mail.from.domain') do |smtp| + # smtp.send_message msgstr, 'from@address', 'to@address' + # end # # === SMTP Authentication # # The Net::SMTP class supports three authentication schemes; # PLAIN, LOGIN and CRAM MD5. (SMTP Authentication: [RFC2554]) # To use SMTP authentication, pass extra arguments to - # SMTP.start/SMTP#start. + # SMTP.start or SMTP#start. # # # PLAIN - # Net::SMTP.start('your.smtp.server', 25 + # Net::SMTP.start('your.smtp.server', 25, # user: 'Your Account', secret: 'Your Password', authtype: :plain) # # LOGIN - # Net::SMTP.start('your.smtp.server', 25 + # Net::SMTP.start('your.smtp.server', 25, # user: 'Your Account', secret: 'Your Password', authtype: :login) # # # CRAM MD5 - # Net::SMTP.start('your.smtp.server', 25 + # Net::SMTP.start('your.smtp.server', 25, # user: 'Your Account', secret: 'Your Password', authtype: :cram_md5) # class SMTP < Protocol