README.md in capistrano-notifier-0.0.2 vs README.md in capistrano-notifier-0.1.0
- old
+ new
@@ -1,38 +1,61 @@
-# CapistranoNotifier
+# Capistrano Notifier [](https://secure.travis-ci.org/cramerdev/capistrano-notifier)
+
## Install
In your Gemfile:
```rb
gem 'capistrano-notifier'
```
and then `bundle install`
-## Configure
+`cap` needs to be invoked with Bundler for the `require` statements
+below to work properly. You can do so with either `bundle exec cap`, or
+with `bundle install --binstubs` and making sure `bin` is high up in your
+`$PATH`.`
+
+## Mail
+
```rb
-require 'capistrano-notifier'
+require 'capistrano/notifier/mail'
-set :notify_method, :test # :smtp, :sendmail, or any other valid ActionMailer delivery method
-set :notify_from, "capistrano@domain.com"
-set :notify_to, ["john@doe.com", "jane@doe.com"]
-set :notify_github_project, "MyCompany/project-name"
+set :notifier_mail_options, {
+ :method => :test, # :smtp, :sendmail, or any other valid ActionMailer delivery method
+ :from => 'capistrano@domain.com',
+ :to => ['john@doe.com', 'jane@doe.com'],
+ :github => 'MyCompany/project-name'
+}
+```
-namespace :deploy do
- desc "Capistrano Notifier"
- task :notify do
- Capistrano::Notifier.new(self).perform
- end
-end
+If you specified `:method => test`, you can see the email that would be
+generated in your console with `cap deploy:notify`.
-after 'deploy', 'deploy:notify'
+
+## StatsD
+
+```rb
+require 'capistrano/notifier/statsd'
```
-## Test
+A counter of 1 will be sent with the key `application.stage.deploy` if using
+multistage, or `application.deploy` if not. To use a gauge instead of a counter,
+use `:with => :gauge`:
-```sh
-cap deploy:notify
+```rb
+set :notifier_statsd_options, {
+ :with => :gauge
+}
```
+If you want to specify a host:port other than
+127.0.0.1:8125, you can do so like this:
+
+```rb
+set :notifier_statsd_options, {
+ :host => "10.0.0.1",
+ :port => "8125"
+}
+```