sanitize_email 0.3.5 → 0.3.6

Sign up to get free protection for your applications and to get access to all the features.
@@ -4,15 +4,15 @@ This gem allows you to globally override your mail delivery settings. It's part
4
4
 
5
5
  It is a "configure it and forget it" type gem that requires very little setup. It includes some very innocuous monkey patching of ActionMailer::Base to work its magic.
6
6
 
7
- Peter Boling wrote the plugin that this gem is derived from. It currently solves three common problems in ruby web applications that use ActionMailer:
7
+ It currently solves three common problems in ruby web applications that use ActionMailer:
8
8
 
9
9
  === Working Locally with Production Data
10
10
 
11
11
  Peter described this common problem in his original plugin implementation as such:
12
12
 
13
13
  * I have a production site with live data.
14
- * I dump the live data and securely transfer it to another machine (rync -e ssh), and import it using scripts that I will soon open source.
15
- * On this separate machine (staging, or development) I run tests, and test various features.
14
+ * I dump the live data and securely transfer it to another machine (rync -e ssh), and import it using a few rake tasks here: http://github.com/pboling/sir-du-bob
15
+ * On this separate machine (staging, or development) I run tests, and test various features which often send out email (registration/signup, order placement, etc.)
16
16
  * I usually want the emails to get sent from these non-production environments so I can verify what they look like when sent, but I don't ever want to risk them getting sent to addresses that are not mine.
17
17
 
18
18
  === Re-routing Email on a Staging or QA Server
@@ -23,10 +23,41 @@ Another very important use case for me is to transparently re-route email genera
23
23
 
24
24
  If you install this gem on a production server (which I don't always do), you can load up script/console and override the to/cc/bcc on all emails for the duration of your console session. This allows you to poke and prod a live production instance, and route all email to your own inbox for inspection. The best part is that this can all be accomplished without changing a single line of your application code.
25
25
 
26
- == Install
26
+ == Install as a RubyGem
27
27
 
28
- gem sources -a http://gems.github.com/
29
- gem install pboling-sanitize_email
28
+ Gem Using Git building from source:
29
+
30
+ mkdir -p ~/src
31
+ cd ~/src
32
+ git clone git://github.com/pboling/sanitize_email.git
33
+ cd sanitize_email
34
+ gem build sanitize_email.gemspec
35
+ sudo gem install sanitize_email-0.3.6.gem # (Or whatever version gets built)
36
+
37
+ Gemcutter is the hot new gem host, and you can use it like this:
38
+
39
+ [sudo] gem install gemcutter
40
+ [sudo] gem tumble # makes gemcutter gem source first in line
41
+ [sudo] gem install sanitize_email
42
+
43
+ Then in your environment.rb (if you are just going to use it from the console, you can require it as needed there, and skip the config.gem):
44
+
45
+ config.gem 'sanitize_email'
46
+
47
+ Then cd to your rails app to optionally freeze the gem into your app (if you roll this way):
48
+
49
+ rake gems:freeze GEM=sanitize_email
50
+
51
+ == Install as a Plugin
52
+
53
+ Plugin using Git:
54
+
55
+ # Installation as plugin works too! (let me know if you find any bugs, as I don't ever run it this way.)
56
+ ./script/plugin install git://github.com/pboling/sanitize_email.git
57
+
58
+ == Install as a Git Submodule (plugin)
59
+
60
+ git submodule add git://github.com/pboling/sanitize_email.git vendor/plugins/sanitize_email
30
61
 
31
62
  == Setup
32
63
 
@@ -104,13 +135,20 @@ Then if you want to send it to the actual user, instead of yourself
104
135
 
105
136
  > User.find(4).test_signup_email_user_only
106
137
 
138
+ == Authors
139
+
140
+ Peter Boling is the author of the gem/plugin. John Trupiano did the initial conversion from plugin to gem as well as improving the code.
141
+
142
+ == Contributors
143
+
144
+ George Anderson's work / improvements has been merged in.
145
+
107
146
  == References
108
- * {RDoc}[http://johntrupiano.rubyforge.org/sanitize_email]
109
147
  * {Source Code}[http://github.com/pboling/sanitize_email]
110
148
  * {Gem Release Announcement}[http://blog.smartlogicsolutions.com/2009/04/25/reintroducing-sanitize_email-work-with-production-email-without-fear/]
111
149
  * {Peter's Original Writeup}[http://galtzo.blogspot.com/2008/11/sanitize-email-never-worry-about.html]
112
150
  * {Using sanitize_email to Preview HTML Emails Locally}[http://blog.smartlogicsolutions.com/2009/04/30/using-sanitize-email-to-preview-html-emails-locally/]
113
151
 
152
+ Copyright (c) 2008-9 {Peter H. Boling}[http://www.peterboling.com/about.html] of {9thBit LLC}[http://www.peterboling.com/]
114
153
  Copyright (c) 2009 {John Trupiano}[http://smartlogicsolutions.com/wiki/John_Trupiano] of {SmartLogic Solutions, LLC}[http://www.smartlogicsolutions.com]
115
- Copyright (c) 2008 {Peter H. Boling}[http://www.peterboling.com/about.html] of {9thBit LLC}[http://www.peterboling.com/]
116
154
  Released under the MIT license
data/Rakefile CHANGED
@@ -6,11 +6,10 @@ begin
6
6
  require 'jeweler'
7
7
  Jeweler::Tasks.new do |gemspec|
8
8
  gemspec.name = "sanitize_email"
9
- #gemspec.rubyforge_project = "johntrupiano"
10
9
  gemspec.summary = "Tool to aid in development, testing, qa, and production troubleshooting of email issues without worrying that emails will get sent to actual live addresses."
11
10
  gemspec.description = %q{Test an application's email abilities without ever sending a message to actual live addresses}
12
11
  gemspec.email = ['peter.boling@gmail.com', 'jtrupiano@gmail.com', 'george@benevolentcode.com']
13
- gemspec.homepage = "http://github.com/pboling/capistrano_mailer"
12
+ gemspec.homepage = "http://github.com/pboling/sanitize_email"
14
13
  gemspec.authors = ["Peter Boling", "John Trupiano", "George Anderson"]
15
14
  gemspec.add_dependency 'actionmailer'
16
15
  gemspec.files = ["lib/sanitize_email/custom_environments.rb",
@@ -1,5 +1,5 @@
1
1
  ---
2
+ :patch: 6
2
3
  :major: 0
3
4
  :minor: 3
4
5
  :build:
5
- :patch: 5
@@ -5,7 +5,7 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{sanitize_email}
8
- s.version = "0.3.5"
8
+ s.version = "0.3.6"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Peter Boling", "John Trupiano", "George Anderson"]
@@ -28,7 +28,7 @@ Gem::Specification.new do |s|
28
28
  "test/sample_mailer.rb",
29
29
  "test/sanitize_email_test.rb"
30
30
  ]
31
- s.homepage = %q{http://github.com/pboling/capistrano_mailer}
31
+ s.homepage = %q{http://github.com/pboling/sanitize_email}
32
32
  s.rdoc_options = ["--charset=UTF-8"]
33
33
  s.require_paths = ["lib"]
34
34
  s.rubygems_version = %q{1.3.5}
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sanitize_email
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.5
4
+ version: 0.3.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Peter Boling
@@ -48,7 +48,7 @@ files:
48
48
  - test/sample_mailer.rb
49
49
  - test/sanitize_email_test.rb
50
50
  has_rdoc: true
51
- homepage: http://github.com/pboling/capistrano_mailer
51
+ homepage: http://github.com/pboling/sanitize_email
52
52
  licenses: []
53
53
 
54
54
  post_install_message: