notification-pusher-actionmailer 1.0.0.beta6 → 1.0.0.beta7
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +31 -0
- data/README.md +51 -27
- data/lib/notification_pusher/action_mailer/engine.rb +8 -0
- data/lib/notification_pusher/action_mailer.rb +11 -0
- data/lib/notification_pusher.rb +5 -0
- metadata +10 -6
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 0d58e52ac6626844bdc8c506db5b0736f6948c98cc1c6c1f0151d9a9f0f0f6ef
|
4
|
+
data.tar.gz: ff0ca32ac607d598c7985ee37f9ef60ff4212b61605db923693ecdbcd0c3d800
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 485631804bbd14d20a6502f96177ba7e852129ef51ab923cd03bfc9a2adbc422b4b0e6f0b0e1f55a7fae6e60678ec2184706d3883a9984c001a7fd985ae625f8
|
7
|
+
data.tar.gz: 29f3b6c1572bcfb26c0045c1537d478665071f646445e24da75088bd4b58f368fa97393a87d05685de3fd775bf98ebc7e8894836a6f8f78a030a6e0e4e21346f
|
data/CHANGELOG.md
ADDED
@@ -0,0 +1,31 @@
|
|
1
|
+
# Changelog
|
2
|
+
|
3
|
+
### master
|
4
|
+
|
5
|
+
* nothing yet
|
6
|
+
|
7
|
+
### 1.0.0.beta6 - 2017-12-28
|
8
|
+
|
9
|
+
* bugfixes
|
10
|
+
* fix lib loading problems
|
11
|
+
|
12
|
+
### 1.0.0.beta5 - 2017-12-28
|
13
|
+
|
14
|
+
* no changes
|
15
|
+
|
16
|
+
### 1.0.0.beta4 - 2017-12-27
|
17
|
+
|
18
|
+
* features
|
19
|
+
* add functionality
|
20
|
+
|
21
|
+
### 1.0.0.beta3 - 2017-12-25
|
22
|
+
|
23
|
+
* no changes
|
24
|
+
|
25
|
+
### 1.0.0.beta2 - 2017-12-23
|
26
|
+
|
27
|
+
* no changes
|
28
|
+
|
29
|
+
### 1.0.0.beta1 - 2017-12-22
|
30
|
+
|
31
|
+
* initial release
|
data/README.md
CHANGED
@@ -1,17 +1,16 @@
|
|
1
|
-
#
|
1
|
+
# NotificationPusher for ActionMailer
|
2
2
|
|
3
|
-
[![Gem Version](https://badge.fury.io/rb/
|
3
|
+
[![Gem Version](https://badge.fury.io/rb/notification-pusher-actionmailer.svg)](https://badge.fury.io/rb/notification-pusher-actionmailer) <img src="https://travis-ci.org/jonhue/notifications-rails.svg?branch=master" />
|
4
4
|
|
5
|
-
|
6
|
-
|
7
|
-
It integrates with the [Native](https://github.com/NativeGap/native-rails) gem to allow you to create a cross platform Rails app.
|
5
|
+
A pusher to send your notifications via email utilizing ActionMailer.
|
8
6
|
|
9
7
|
---
|
10
8
|
|
11
9
|
## Table of Contents
|
12
10
|
|
13
|
-
* [Philosophy](#philosophy)
|
14
11
|
* [Installation](#installation)
|
12
|
+
* [Usage](#usage)
|
13
|
+
* [Options](#options)
|
15
14
|
* [To Do](#to-do)
|
16
15
|
* [Contributing](#contributing)
|
17
16
|
* [Contributors](#contributors)
|
@@ -20,49 +19,74 @@ It integrates with the [Native](https://github.com/NativeGap/native-rails) gem t
|
|
20
19
|
|
21
20
|
---
|
22
21
|
|
23
|
-
##
|
22
|
+
## Installation
|
24
23
|
|
25
|
-
|
24
|
+
NotificationPusher for ActionMailer works with Rails 5 onwards. You can add it to your `Gemfile` with:
|
26
25
|
|
27
|
-
|
26
|
+
```ruby
|
27
|
+
gem 'notification-pusher-actionmailer'
|
28
|
+
```
|
28
29
|
|
29
|
-
|
30
|
+
And then execute:
|
30
31
|
|
31
|
-
|
32
|
+
$ bundle
|
32
33
|
|
33
|
-
|
34
|
+
Or install it yourself as:
|
34
35
|
|
35
|
-
|
36
|
+
$ gem install notification-pusher-actionmailer
|
37
|
+
|
38
|
+
If you always want to be up to date fetch the latest from GitHub in your `Gemfile`:
|
39
|
+
|
40
|
+
```ruby
|
41
|
+
gem 'notification-pusher-actionmailer', github: 'jonhue/notifications-rails'
|
42
|
+
```
|
36
43
|
|
37
44
|
---
|
38
45
|
|
39
|
-
##
|
46
|
+
## Usage
|
40
47
|
|
41
|
-
|
48
|
+
Define this pusher in your `NotificationPusher` configuration:
|
42
49
|
|
43
50
|
```ruby
|
44
|
-
|
51
|
+
NotificationPusher.configure do |config|
|
52
|
+
config.define_pusher :ActionMailer
|
53
|
+
end
|
45
54
|
```
|
46
55
|
|
47
|
-
|
48
|
-
|
49
|
-
$ bundle
|
56
|
+
You can pass a `from` parameter, which will override the default email address specified in `ApplicationMailer`:
|
50
57
|
|
51
|
-
|
58
|
+
```ruby
|
59
|
+
NotificationPusher.configure do |config|
|
60
|
+
config.define_pusher :ActionMailer, from: 'my@email.com'
|
61
|
+
end
|
62
|
+
```
|
52
63
|
|
53
|
-
|
64
|
+
Then add a renderer called `_actionmailer.html.erb` to every notification type you aim to support. Learn more [here](https://github.com/jonhue/notifications-rails/tree/master/notification-renderer).
|
54
65
|
|
55
|
-
|
66
|
+
Now you can push your notifications:
|
56
67
|
|
57
68
|
```ruby
|
58
|
-
|
69
|
+
notification = Notification.create target: User.first, object: Recipe.first
|
70
|
+
notification.push :ActionMailer, to: 'another@email.com'
|
59
71
|
```
|
60
72
|
|
73
|
+
**Note:** If the email address, you want to push to, is the same as `notification.target.email` you can omit the `to` parameter.
|
74
|
+
|
75
|
+
It is also possible to override the email address sending this notification, by passing a `from` parameter.
|
76
|
+
|
77
|
+
### Options
|
78
|
+
|
79
|
+
**`to`** Receiver email address. Takes a string.
|
80
|
+
|
81
|
+
**`from`** Sender email address. Takes a string. Defaults to email specified in `ApplicationMailer`.
|
82
|
+
|
83
|
+
**`renderer`** Specify a renderer. Takes a string. Defaults to `'actionmailer'`.
|
84
|
+
|
61
85
|
---
|
62
86
|
|
63
87
|
## To Do
|
64
88
|
|
65
|
-
[Here](https://github.com/jonhue/notifications-rails/projects) is the full list of current projects.
|
89
|
+
[Here](https://github.com/jonhue/notifications-rails/projects/6) is the full list of current projects.
|
66
90
|
|
67
91
|
To propose your ideas, initiate the discussion by adding a [new issue](https://github.com/jonhue/notifications-rails/issues/new).
|
68
92
|
|
@@ -70,9 +94,9 @@ To propose your ideas, initiate the discussion by adding a [new issue](https://g
|
|
70
94
|
|
71
95
|
## Contributing
|
72
96
|
|
73
|
-
We hope that you will consider contributing to
|
97
|
+
We hope that you will consider contributing to NotificationPusher for ActionMailer. Please read this short overview for some information about how to get started:
|
74
98
|
|
75
|
-
[Learn more about contributing to this repository](CONTRIBUTING.md), [Code of Conduct](CODE_OF_CONDUCT.md)
|
99
|
+
[Learn more about contributing to this repository](https://github.com/jonhue/notifications-rails/blob/master/CONTRIBUTING.md), [Code of Conduct](https://github.com/jonhue/notifications-rails/blob/master/CODE_OF_CONDUCT.md)
|
76
100
|
|
77
101
|
### Contributors
|
78
102
|
|
@@ -82,7 +106,7 @@ https://github.com/jonhue/notifications-rails/graphs/contributors
|
|
82
106
|
|
83
107
|
### Semantic Versioning
|
84
108
|
|
85
|
-
|
109
|
+
NotificationPusher for ActionMailer follows Semantic Versioning 2.0 as defined at http://semver.org.
|
86
110
|
|
87
111
|
## License
|
88
112
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: notification-pusher-actionmailer
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.0.
|
4
|
+
version: 1.0.0.beta7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jonas Hübotter
|
@@ -44,28 +44,28 @@ dependencies:
|
|
44
44
|
requirements:
|
45
45
|
- - '='
|
46
46
|
- !ruby/object:Gem::Version
|
47
|
-
version: 1.0.0.
|
47
|
+
version: 1.0.0.beta7
|
48
48
|
type: :runtime
|
49
49
|
prerelease: false
|
50
50
|
version_requirements: !ruby/object:Gem::Requirement
|
51
51
|
requirements:
|
52
52
|
- - '='
|
53
53
|
- !ruby/object:Gem::Version
|
54
|
-
version: 1.0.0.
|
54
|
+
version: 1.0.0.beta7
|
55
55
|
- !ruby/object:Gem::Dependency
|
56
56
|
name: notification-renderer
|
57
57
|
requirement: !ruby/object:Gem::Requirement
|
58
58
|
requirements:
|
59
59
|
- - '='
|
60
60
|
- !ruby/object:Gem::Version
|
61
|
-
version: 1.0.0.
|
61
|
+
version: 1.0.0.beta7
|
62
62
|
type: :runtime
|
63
63
|
prerelease: false
|
64
64
|
version_requirements: !ruby/object:Gem::Requirement
|
65
65
|
requirements:
|
66
66
|
- - '='
|
67
67
|
- !ruby/object:Gem::Version
|
68
|
-
version: 1.0.0.
|
68
|
+
version: 1.0.0.beta7
|
69
69
|
- !ruby/object:Gem::Dependency
|
70
70
|
name: rspec
|
71
71
|
requirement: !ruby/object:Gem::Requirement
|
@@ -100,8 +100,12 @@ executables: []
|
|
100
100
|
extensions: []
|
101
101
|
extra_rdoc_files: []
|
102
102
|
files:
|
103
|
+
- CHANGELOG.md
|
103
104
|
- LICENSE
|
104
105
|
- README.md
|
106
|
+
- lib/notification_pusher.rb
|
107
|
+
- lib/notification_pusher/action_mailer.rb
|
108
|
+
- lib/notification_pusher/action_mailer/engine.rb
|
105
109
|
homepage: https://github.com/jonhue/notifications-rails/tree/master/notification-pusher/notification-pusher-actionmailer
|
106
110
|
licenses:
|
107
111
|
- MIT
|
@@ -109,7 +113,7 @@ metadata: {}
|
|
109
113
|
post_install_message:
|
110
114
|
rdoc_options: []
|
111
115
|
require_paths:
|
112
|
-
- lib
|
116
|
+
- lib
|
113
117
|
required_ruby_version: !ruby/object:Gem::Requirement
|
114
118
|
requirements:
|
115
119
|
- - ">="
|