README.md in slackistrano-1.0.0 vs README.md in slackistrano-1.1.0
- old
+ new
@@ -56,10 +56,17 @@
set :slack_team, "teamname"
set :slack_token, "xxxxxxxxxxxxxxxxxxxxxxxx"
set :slack_channel, '#general'
```
+You can set `:slack_channel` (or any of the `:slack_channel_xxxx` settings) to an array and Slackistrano
+will post to each channel. For example:
+
+```ruby
+set :slack_channel, ['#general', '#ops']
+```
+
Optionally, override the other slack settings.
```ruby
set :slack_channel_updating, -> { nil } # Channel to post to. Defaults to :slack_channel.
set :slack_channel_reverting, -> { nil } # Channel to post to. Defaults to :slack_channel.
@@ -126,14 +133,13 @@
## Formatted messages
Slack allows you to send complex content, composed by fields. You can use the `fields` and `fallback` variables in order to have a well formatted message as follows:
```ruby
-set :slack_revision, `git rev-parse origin/master`.strip!
-set :slack_title_finished, nil
-set :slack_msg_finished, nil
-set :slack_fallback_finished, "#{fetch(:slack_deploy_user)} deployed #{fetch(:application)} on #{fetch(:stage)}"
-set :slack_fields_finished, [
+set :slack_revision, `git rev-parse origin/#{fetch(:branch)}`.strip!
+set :slack_msg_updated, nil
+set :slack_fallback_updated, "#{fetch(:slack_deploy_user)} deployed #{fetch(:application)} on #{fetch(:stage)}"
+set :slack_fields_updated, [
{
"title": "Project",
"value": "<https://github.com/XXXXX/#{fetch(:application)}|#{fetch(:application)}>",
"short": true
},