pairing_shuffler 0.0.4 → 0.0.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data.tar.gz.sig +0 -0
- data/lib/pairing_shuffler.rb +13 -11
- data/lib/pairing_shuffler/version.rb +1 -1
- metadata +4 -4
- metadata.gz.sig +0 -0
data.tar.gz.sig
CHANGED
|
Binary file
|
data/lib/pairing_shuffler.rb
CHANGED
|
@@ -70,7 +70,7 @@ module PairingShuffler
|
|
|
70
70
|
subject = "PairingShuffler winners"
|
|
71
71
|
# FYI: if the first line is a url the email is blank in gmail
|
|
72
72
|
body = <<-MAIL.gsub(/^ {8}/, "")
|
|
73
|
-
Hello
|
|
73
|
+
Hello #{emails.map{|e|e.sub(/@.*/,"")}.join(" & ")}!
|
|
74
74
|
|
|
75
75
|
You both singed up for PairingShuffler at https://docs.google.com/spreadsheet/ccc?key=#{config[:doc]}
|
|
76
76
|
so let's pair!
|
|
@@ -89,16 +89,18 @@ module PairingShuffler
|
|
|
89
89
|
|
|
90
90
|
private
|
|
91
91
|
|
|
92
|
-
def send_email(
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
92
|
+
def send_email(tos, options={})
|
|
93
|
+
tos.each do |to|
|
|
94
|
+
message = <<-MESSAGE.gsub(/^ {10}/, "")
|
|
95
|
+
From: PairingShuffler <#{config.fetch(:username)}>
|
|
96
|
+
To: #{to}
|
|
97
|
+
Reply-To: #{(tos - [to]).join(", ")}
|
|
98
|
+
Subject: #{options.fetch(:subject)}
|
|
99
|
+
|
|
100
|
+
#{options.fetch(:body)}
|
|
101
|
+
MESSAGE
|
|
102
|
+
smtp.send_message message, config.fetch(:username), to
|
|
103
|
+
end
|
|
102
104
|
end
|
|
103
105
|
|
|
104
106
|
def smtp
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: pairing_shuffler
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.0.
|
|
4
|
+
version: 0.0.5
|
|
5
5
|
prerelease:
|
|
6
6
|
platform: ruby
|
|
7
7
|
authors:
|
|
@@ -36,7 +36,7 @@ cert_chain:
|
|
|
36
36
|
VHNmKzZNYWVud0FNa0FnSGRzd0dzSnp0T25ObkJhM0YKeTBrQ1NXbUs2RCt4
|
|
37
37
|
L1NiZlM2cjdLZTA3TVJxemlKZEI5R3VFMSswY0lSdUZoOEVRK0xONkhYQ0tN
|
|
38
38
|
NXBvbi9HVQp5Y3dNWGZsMAotLS0tLUVORCBDRVJUSUZJQ0FURS0tLS0tCg==
|
|
39
|
-
date: 2013-06-
|
|
39
|
+
date: 2013-06-27 00:00:00.000000000 Z
|
|
40
40
|
dependencies:
|
|
41
41
|
- !ruby/object:Gem::Dependency
|
|
42
42
|
name: google_drive
|
|
@@ -77,7 +77,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
|
77
77
|
version: '0'
|
|
78
78
|
segments:
|
|
79
79
|
- 0
|
|
80
|
-
hash:
|
|
80
|
+
hash: -2018229648239218957
|
|
81
81
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
82
82
|
none: false
|
|
83
83
|
requirements:
|
|
@@ -86,7 +86,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
86
86
|
version: '0'
|
|
87
87
|
segments:
|
|
88
88
|
- 0
|
|
89
|
-
hash:
|
|
89
|
+
hash: -2018229648239218957
|
|
90
90
|
requirements: []
|
|
91
91
|
rubyforge_project:
|
|
92
92
|
rubygems_version: 1.8.25
|
metadata.gz.sig
CHANGED
|
Binary file
|