tuktuk 0.6.2 → 0.6.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 661740803e484f1a5e14110e418873905dccc026
4
- data.tar.gz: 6e6182e60e5e90f4a02671ef9e992d3557115a4d
3
+ metadata.gz: 9b23aad601ecb20c8e9f2a61ca0c5d8740fe08fb
4
+ data.tar.gz: ccd26989dcc9cf8ea0cd124bc117cd8aa4ebe337
5
5
  SHA512:
6
- metadata.gz: c0ac622ec549fe687a5ebfe47b7834f5eda79cb6a8948c0aba8945bd0fd07ea98df511488a28dc752cbc36a5ff4b51d7104f3153c637b4d909102d5410b8a6c6
7
- data.tar.gz: ec4cd6bb21d92d189ea0508ba9943b8fb8b428ea2bb29e8ae927a87093d9fc3f3ef25fb61fc862a6e044d8c6eb8ce6272bc0ef9959a9233b7520670571b03ae0
6
+ metadata.gz: 573938ae9b56c2fea03e8cf19ae133b298e146232813b022ee2cc17e275e68cf98a353e4863eec720da3a898a7e78d3ba59926963db846bc02f215cb87eaf92f
7
+ data.tar.gz: 0fb02b910a04a3f0e2472e7e65264add4eed11cc12a46f68b3a1adf820f9ff615392d24a65831da98aafa95f0a909d828f68454192111706aad905ee5fc487a1
data/README.md CHANGED
@@ -160,7 +160,7 @@ Tuktuk.options = {
160
160
 
161
161
  You can set the `max_workers` option to `auto`, which will spawn the necessary threads to connect in paralell to all target MX servers when delivering multiple messages. When set to `0`, these batches will be delivered sequentially.
162
162
 
163
- In other words, if you have three emails targeted to Gmail users and two for Hotmail users, using `auto` Tuktuk will spawn two threads and connect to both servers at once. Using `0` will have email deliveried to one host and then the other.
163
+ In other words, if you have three emails targeted to Gmail users and two for Hotmail users, using `auto` Tuktuk will spawn two threads and connect to both servers at once. Using `0` will have your emails delivered to one host, and then the other.
164
164
 
165
165
  Using with Rails
166
166
  ----------------
data/_config.yml ADDED
@@ -0,0 +1 @@
1
+ theme: jekyll-theme-minimal
data/lib/tuktuk/bounce.rb CHANGED
@@ -15,7 +15,7 @@ class Bounce < RuntimeError
15
15
  ]
16
16
 
17
17
  def self.type(e)
18
- if e.is_a?(Net::SMTPFatalError) and code = e.to_s[0..2] and HARD_BOUNCE_CODES.include? code.to_i
18
+ if e.is_a?(Net::SMTPFatalError) and code = e.to_s[0..2] and HARD_BOUNCE_CODES.include?(code.to_i)
19
19
  HardBounce.new(e)
20
20
  else
21
21
  SoftBounce.new(e) # either soft mailbox bounce, timeout or server bounce
data/lib/tuktuk/tuktuk.rb CHANGED
@@ -266,12 +266,18 @@ module Tuktuk
266
266
  context.verify_mode = config[:verify_ssl] ?
267
267
  OpenSSL::SSL::VERIFY_PEER : OpenSSL::SSL::VERIFY_NONE
268
268
 
269
+ port = nil
269
270
  if config[:debug]
270
- logger.warn "Debug option enabled. Connecting to localhost!"
271
- server = 'localhost'
271
+ if config[:debug].is_a?(String)
272
+ server = config[:debug].split(':').first
273
+ port = config[:debug].split(':').last if config[:debug][':']
274
+ else
275
+ server = 'localhost'
276
+ end
277
+ logger.warn "Debug option enabled. Connecting to #{server}!"
272
278
  end
273
279
 
274
- smtp = Net::SMTP.new(server, nil)
280
+ smtp = Net::SMTP.new(server, port)
275
281
  smtp.enable_starttls_auto(context)
276
282
  smtp.read_timeout = config[:read_timeout] if config[:read_timeout]
277
283
  smtp.open_timeout = config[:open_timeout] if config[:open_timeout]
@@ -1,7 +1,7 @@
1
1
  module Tuktuk
2
2
  MAJOR = 0
3
3
  MINOR = 6
4
- PATCH = 2
4
+ PATCH = 3
5
5
 
6
6
  VERSION = [MAJOR, MINOR, PATCH].join('.')
7
7
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tuktuk
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.6.2
4
+ version: 0.6.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tomás Pollak
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-07-24 00:00:00.000000000 Z
11
+ date: 2018-12-03 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -92,6 +92,7 @@ files:
92
92
  - Gemfile
93
93
  - README.md
94
94
  - Rakefile
95
+ - _config.yml
95
96
  - bin/tuktuk
96
97
  - lib/tuktuk.rb
97
98
  - lib/tuktuk/bounce.rb