fcm-rails-push-notifications 0.2.4 → 0.2.5

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: 9598012750f8ccf4873ae6e5985bc978c9f504be
4
- data.tar.gz: 7e12d994ea80a6ff257fd2c945ab6a4d51006cfe
3
+ metadata.gz: 597d72723ee65e2c21673742930044cffcee79b0
4
+ data.tar.gz: 7f29a6e0545411b8f93415672b26ced9ab2ea053
5
5
  SHA512:
6
- metadata.gz: 9c8fa43b070c14df34d558812f2a7e2ce7c0232ae6e6bffee160dc058a518f62a879865ec54f651243143001908eb36dd731d8d3e8230ef43837708fa8ccd01b
7
- data.tar.gz: 06953b99a1168dc985ee990c545bb185336f2e3d1e1c27b608240fb970bde432157292d11bb8bcbef5077109bf182d50f40e0bec8d212620d6e122e04f6331e2
6
+ metadata.gz: 047b8ef676e27f1697ebd0b3897b6f76748da77fbb43683ef184787053ea0e7941a012ad6808cb927b6fb4d6e14af2d1d61b9d078b6a577a560fb2bcd8564f3d
7
+ data.tar.gz: 549101b4f0bc6b033c368e188be7c5e95161074ccaada15ac9f9e6ef75d7b770117fdb7756728dcd6dc0ad62461c8d155351856bd432ce51605eda27d4bc9c32
data/README.md CHANGED
@@ -1,7 +1,8 @@
1
1
  # Rails Push Notifications
2
- [![Build Status](https://travis-ci.org/calonso/rails-push-notifications.svg)](https://travis-ci.org/calonso/rails-push-notifications) [![Code Climate](https://codeclimate.com/github/calonso/rails-push-notifications/badges/gpa.svg)](https://codeclimate.com/github/calonso/rails-push-notifications) [![Test Coverage](https://codeclimate.com/github/calonso/rails-push-notifications/badges/coverage.svg)](https://codeclimate.com/github/calonso/rails-push-notifications/coverage)
2
+ <!-- [![Build Status](https://travis-ci.org/calonso/rails-push-notifications.svg)](https://travis-ci.org/calonso/rails-push-notifications) [![Code Climate](https://codeclimate.com/github/calonso/rails-push-notifications/badges/gpa.svg)](https://codeclimate.com/github/calonso/rails-push-notifications) [![Test Coverage](https://codeclimate.com/github/calonso/rails-push-notifications/badges/coverage.svg)](https://codeclimate.com/github/calonso/rails-push-notifications/coverage) -->
3
3
  ## Professional iOS, Android and Windows Phone push notifications for Ruby on Rails
4
4
 
5
+ FcmRailsPushNotifications is build on top of RailsPushNotifications for supporting FCM.
5
6
  RailsPushNotifications is an intuitive and easy to use gem that will allow you to easily add Push Notifications to your project.
6
7
 
7
8
  RailsPushNotifications key features:
@@ -21,7 +22,7 @@ The source code for that project is here: [https://github.com/calonso/rails_push
21
22
  ## Installation
22
23
  To install the gem simply add this line to your Gemfile
23
24
 
24
- gem 'rails-push-notifications', '~> 0.2.0'
25
+ gem 'fcm-rails-push-notifications', '~> 0.2.4'
25
26
 
26
27
  and then install it by running
27
28
 
@@ -70,6 +71,14 @@ The only thing you need is the API_KEY that you will get from the Google APIS Co
70
71
 
71
72
  That's all. You have your applications' configurations stored in RailsPushNotification.
72
73
 
74
+ ### Android Applications setup using FCM
75
+
76
+ The only thing you need is the API_KEY that you will get from the Google APIS Console for FCM
77
+
78
+ app = RailsPushNotifications::FCMApp.new
79
+ app.fcm_key = '<your app api key>'
80
+ app.save
81
+
73
82
  ### WindowsPhone Applications setup
74
83
 
75
84
  This case is similar but even simpler than APNS Apps
@@ -105,6 +114,17 @@ the destinations and the data format will vary, so for example
105
114
  data: { message: 'Hello GCM World!' }
106
115
  )
107
116
 
117
+ ### FCM Notifications
118
+
119
+ app = <Your FCM app>
120
+ notification = app.notifications.create(
121
+ destinations: [
122
+ 'Your first destination token',
123
+ 'Your second destination token'
124
+ ],
125
+ data: { message: 'Hello FCM World!' }
126
+ )
127
+
108
128
  ### WindowsPhone Notifications
109
129
 
110
130
  app = <Your WindowsPhone app>
@@ -142,7 +162,7 @@ to avoid bugs.
142
162
 
143
163
  ## Contributing
144
164
 
145
- 1. Fork it ( https://github.com/calonso/rails-push-notifications/fork )
165
+ 1. Fork it ( https://github.com/santhums/rails-push-notifications/fork )
146
166
  2. Create your feature branch (`git checkout -b my-new-feature`)
147
167
  3. Commit your changes (`git commit -am 'Add some feature'`)
148
168
  4. Push to the branch (`git push origin my-new-feature`)
@@ -1,4 +1,4 @@
1
- require 'ruby-push-notifications'
1
+ require 'fcm-ruby-push-notifications'
2
2
  require 'rails-push-notifications/apps'
3
3
  require 'rails-push-notifications/notification'
4
4
  require 'rails-push-notifications/rails_push_notifications_railtie'
@@ -1,3 +1,3 @@
1
1
  module RailsPushNotifications
2
- VERSION = '0.2.4'
2
+ VERSION = '0.2.5'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fcm-rails-push-notifications
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.4
4
+ version: 0.2.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Santhu MS
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-07-25 00:00:00.000000000 Z
11
+ date: 2018-07-26 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -30,14 +30,14 @@ dependencies:
30
30
  requirements:
31
31
  - - ">="
32
32
  - !ruby/object:Gem::Version
33
- version: 1.2.1
33
+ version: 1.2.2
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - ">="
39
39
  - !ruby/object:Gem::Version
40
- version: 1.2.1
40
+ version: 1.2.2
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: sqlite3
43
43
  requirement: !ruby/object:Gem::Requirement
@@ -132,11 +132,11 @@ files:
132
132
  - MIT-LICENSE
133
133
  - README.md
134
134
  - Rakefile
135
+ - lib/fcm-rails-push-notifications.rb
135
136
  - lib/generators/rails-push-notifications/USAGE
136
137
  - lib/generators/rails-push-notifications/migrations_generator.rb
137
138
  - lib/generators/rails-push-notifications/templates/migrations/create_rails_push_notifications_apps.rb
138
139
  - lib/generators/rails-push-notifications/templates/migrations/create_rails_push_notifications_notifications.rb
139
- - lib/rails-push-notifications.rb
140
140
  - lib/rails-push-notifications/apps.rb
141
141
  - lib/rails-push-notifications/apps/apns_app.rb
142
142
  - lib/rails-push-notifications/apps/base_app.rb