c2dm 0.1.3 → 0.1.4
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/README.markdown +5 -1
- data/VERSION +1 -1
- data/c2dm.gemspec +1 -1
- data/lib/c2dm.rb +4 -0
- metadata +2 -2
data/README.markdown
CHANGED
|
@@ -44,4 +44,8 @@ Sending many notifications:
|
|
|
44
44
|
|
|
45
45
|
##Copyrights
|
|
46
46
|
|
|
47
|
-
* Copyright (c) 2010-2011 Amro Mousa. See LICENSE.txt for details.
|
|
47
|
+
* Copyright (c) 2010-2011 Amro Mousa. See LICENSE.txt for details.
|
|
48
|
+
|
|
49
|
+
##Other stuff
|
|
50
|
+
|
|
51
|
+
You might want to checkout GroupMe's fork of this gem as well.
|
data/VERSION
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
0.1.
|
|
1
|
+
0.1.4
|
data/c2dm.gemspec
CHANGED
data/lib/c2dm.rb
CHANGED
|
@@ -12,6 +12,10 @@ class C2DM
|
|
|
12
12
|
DEFAULT_SOURCE = 'MyCompany-MyAppName-1.0'
|
|
13
13
|
|
|
14
14
|
def initialize(username, password, source = DEFAULT_SOURCE)
|
|
15
|
+
auth(username, password, source)
|
|
16
|
+
end
|
|
17
|
+
|
|
18
|
+
def auth(username, password, source)
|
|
15
19
|
post_body = "accountType=HOSTED_OR_GOOGLE&Email=#{username}&Passwd=#{password}&service=ac2dm&source=#{source}"
|
|
16
20
|
params = {
|
|
17
21
|
:body => post_body,
|
metadata
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
name: c2dm
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
4
|
prerelease:
|
|
5
|
-
version: 0.1.
|
|
5
|
+
version: 0.1.4
|
|
6
6
|
platform: ruby
|
|
7
7
|
authors:
|
|
8
8
|
- Amro Mousa
|
|
@@ -103,7 +103,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
|
103
103
|
requirements:
|
|
104
104
|
- - ">="
|
|
105
105
|
- !ruby/object:Gem::Version
|
|
106
|
-
hash:
|
|
106
|
+
hash: -2523248155411028688
|
|
107
107
|
segments:
|
|
108
108
|
- 0
|
|
109
109
|
version: "0"
|