Skip to content

Commit

Permalink
support :file delivery_method, version bump to 1.0.1
Browse files Browse the repository at this point in the history
  • Loading branch information
labocho committed Jan 30, 2013
1 parent 09c4456 commit a696b7f
Show file tree
Hide file tree
Showing 4 changed files with 34 additions and 6 deletions.
24 changes: 22 additions & 2 deletions README.md
Expand Up @@ -8,7 +8,22 @@
port: 1234
)

for Rails
for Rails, please make config/mail.yml like below.

development:
delivery_method: mailcatcher

test:
delivery_method: test

production:
delivery_method: smtp
# smtp_settings
address: mail.example.com
user_name: noreply@example.com
password: xxxxxx

and add `require "action_mailer_config/rails"` to config/application.rb.

# config/initializer/application.rb
module YourApplication
Expand All @@ -18,7 +33,12 @@ for Rails
end
end

## Contributing to action_mailer_config
## Delivery method

`smtp`, `sendmail`, `file`, `test` or `mailcatcher` are available.
mailcatcher requires mailcatcher gem (http://rubygems.org/gems/mailcatcher) and run command `mailcatcher`.

## Contributing to action\_mailer\_config

* Check out the latest master to make sure the feature hasn't been implemented or the bug hasn't been fixed yet
* Check out the issue tracker to make sure someone already hasn't requested it and/or contributed it
Expand Down
12 changes: 9 additions & 3 deletions action_mailer_config.gemspec
Expand Up @@ -5,31 +5,37 @@

Gem::Specification.new do |s|
s.name = "action_mailer_config"
s.version = "1.0.0"
s.version = "1.0.1"

s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
s.authors = ["labocho"]
s.date = "2012-06-12"
s.date = "2013-01-30"
s.description = "Load ActionMailer configuration from YAML"
s.email = "labocho@penguinlab.jp"
s.extra_rdoc_files = [
"LICENSE.txt",
"README.md"
]
s.files = [
".cleancode",
".document",
".rspec",
"Gemfile",
"Gemfile.lock",
"LICENSE.txt",
"README.md",
"Rakefile",
"action_mailer_config.gemspec",
"lib/action_mailer_config.rb",
"lib/action_mailer_config/rails.rb",
"lib/action_mailer_config/version.rb",
"spec/action_mailer_config_spec.rb",
"spec/spec_helper.rb"
]
s.homepage = "http://github.com/labocho/action_mailer_config"
s.licenses = ["MIT"]
s.require_paths = ["lib"]
s.rubygems_version = "1.8.17"
s.rubygems_version = "1.8.24"
s.summary = "Load ActionMailer configuration from YAML"

if s.respond_to? :specification_version then
Expand Down
2 changes: 2 additions & 0 deletions lib/action_mailer_config.rb
Expand Up @@ -9,6 +9,8 @@ def load(config)
self.smtp_settings = config
when :sendmail
self.sendmail_settings = config
when :file
self.file_settings = config
when :mailcatcher
self.delivery_method = :smtp
self.smtp_settings = {
Expand Down
2 changes: 1 addition & 1 deletion lib/action_mailer_config/version.rb
@@ -1,3 +1,3 @@
module ActionMailerConfig
VERSION = "1.0.0"
VERSION = "1.0.1"
end

0 comments on commit a696b7f

Please sign in to comment.