simply_notify 0.1.1 → 0.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +4 -16
- data/lib/generators/notifier_generator.rb +18 -0
- data/lib/simply_notify/version.rb +1 -1
- data/simply_notify.gemspec +4 -3
- metadata +21 -5
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f4fd5c39e89d9d8383fc28ceb06e1cfd5b912fd2
|
4
|
+
data.tar.gz: 368fc3d3dd49c55f543c2ddbea951f3250a2bd2e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f1359313017d8e09e441c7bb5ef9f0337842943f318efed1e7a359628cd5249194f5f8c521ec13618066a3e77c463dfdb6ec1da09de345f91ac6f51fa85f9ae2
|
7
|
+
data.tar.gz: 40facb99fcd5c198b1fe13a37500197f7d5c360800c53e57f503a699388737694bdf1e9f6027aa4ecd8fc78fe262b1031900117140449311931d802a9596e8ea
|
data/README.md
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
# SimplyNotify
|
2
2
|
|
3
|
-
simply_notify will send a user of the course website an email notifying the user of a new notification that has been posted to their account.
|
3
|
+
simply_notify will send a user of the Brandeis University course website an email notifying the user of a new notification that has been posted to their account.
|
4
4
|
|
5
5
|
|
6
6
|
## Installation
|
@@ -22,23 +22,11 @@ Or install it yourself as:
|
|
22
22
|
|
23
23
|
## Usage
|
24
24
|
|
25
|
-
|
25
|
+
Create the model and views using the generator:
|
26
26
|
|
27
|
-
notifier
|
27
|
+
rails generate notifier
|
28
28
|
|
29
|
-
In the
|
30
|
-
|
31
|
-
require 'simply_notify'
|
32
|
-
|
33
|
-
Create mailer views in your app. For example:
|
34
|
-
|
35
|
-
app/views/notifier/new_notification.text.erb
|
36
|
-
|
37
|
-
AND
|
38
|
-
|
39
|
-
app/views/notifier/new_notification.html.erb
|
40
|
-
|
41
|
-
In the views you created, place a message such as this:
|
29
|
+
In the views (text and html respectively), place a message such as this:
|
42
30
|
|
43
31
|
Hello <%= @recipient %>,
|
44
32
|
You have a new notification! Please visit the course website.
|
@@ -0,0 +1,18 @@
|
|
1
|
+
require "rails/generators"
|
2
|
+
require "thor"
|
3
|
+
|
4
|
+
class NotifierGenerator < Rails::Generators::Base
|
5
|
+
desc "This generator creates the Model and Views"
|
6
|
+
|
7
|
+
def create_model_file
|
8
|
+
create_file "models/notifier.rb", "require 'simply_notify'"
|
9
|
+
end
|
10
|
+
|
11
|
+
def create_html_view_file
|
12
|
+
create_file "views/notifier/html.html.erb", "# Put html here"
|
13
|
+
end
|
14
|
+
|
15
|
+
def create_text_view_file
|
16
|
+
create_file "views/notifier/text.html.erb", "# Put text here"
|
17
|
+
end
|
18
|
+
end
|
data/simply_notify.gemspec
CHANGED
@@ -9,8 +9,8 @@ Gem::Specification.new do |spec|
|
|
9
9
|
spec.authors = ["Tyler Lichten"]
|
10
10
|
spec.email = ["tlich10@gmail.com"]
|
11
11
|
|
12
|
-
spec.summary = %q{Delivers email notifications to users of a course website}
|
13
|
-
spec.description = %q{Delivers email notifications to users of a course website}
|
12
|
+
spec.summary = %q{Delivers email notifications to users of a Brandeis University course website}
|
13
|
+
spec.description = %q{Delivers email notifications to users of a Brandeis University course website}
|
14
14
|
spec.homepage = ""
|
15
15
|
spec.license = "MIT"
|
16
16
|
|
@@ -20,9 +20,10 @@ Gem::Specification.new do |spec|
|
|
20
20
|
spec.require_paths = ["lib"]
|
21
21
|
|
22
22
|
spec.add_runtime_dependency "actionmailer"
|
23
|
+
spec.add_runtime_dependency "thor"
|
23
24
|
|
24
25
|
spec.add_development_dependency "bundler", "~> 1.11"
|
25
26
|
spec.add_development_dependency "rake", "~> 10.0"
|
26
27
|
spec.add_development_dependency "rspec", "~> 3.0"
|
27
|
-
spec.add_development_dependency "
|
28
|
+
spec.add_development_dependency "generator_spec"
|
28
29
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: simply_notify
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Tyler Lichten
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-02-
|
11
|
+
date: 2016-02-28 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: actionmailer
|
@@ -24,6 +24,20 @@ dependencies:
|
|
24
24
|
- - ">="
|
25
25
|
- !ruby/object:Gem::Version
|
26
26
|
version: '0'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: thor
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - ">="
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '0'
|
34
|
+
type: :runtime
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - ">="
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '0'
|
27
41
|
- !ruby/object:Gem::Dependency
|
28
42
|
name: bundler
|
29
43
|
requirement: !ruby/object:Gem::Requirement
|
@@ -67,7 +81,7 @@ dependencies:
|
|
67
81
|
- !ruby/object:Gem::Version
|
68
82
|
version: '3.0'
|
69
83
|
- !ruby/object:Gem::Dependency
|
70
|
-
name:
|
84
|
+
name: generator_spec
|
71
85
|
requirement: !ruby/object:Gem::Requirement
|
72
86
|
requirements:
|
73
87
|
- - ">="
|
@@ -80,7 +94,8 @@ dependencies:
|
|
80
94
|
- - ">="
|
81
95
|
- !ruby/object:Gem::Version
|
82
96
|
version: '0'
|
83
|
-
description: Delivers email notifications to users of a course
|
97
|
+
description: Delivers email notifications to users of a Brandeis University course
|
98
|
+
website
|
84
99
|
email:
|
85
100
|
- tlich10@gmail.com
|
86
101
|
executables: []
|
@@ -96,6 +111,7 @@ files:
|
|
96
111
|
- Rakefile
|
97
112
|
- bin/console
|
98
113
|
- bin/setup
|
114
|
+
- lib/generators/notifier_generator.rb
|
99
115
|
- lib/simply_notify.rb
|
100
116
|
- lib/simply_notify/version.rb
|
101
117
|
- simply_notify.gemspec
|
@@ -122,5 +138,5 @@ rubyforge_project:
|
|
122
138
|
rubygems_version: 2.5.1
|
123
139
|
signing_key:
|
124
140
|
specification_version: 4
|
125
|
-
summary: Delivers email notifications to users of a course website
|
141
|
+
summary: Delivers email notifications to users of a Brandeis University course website
|
126
142
|
test_files: []
|