class CruisecontrolrbToSlack::SlackClient
Attributes
client[R]
Public Class Methods
new(webhook, options = {})
click to toggle source
# File lib/cruisecontrolrb-to-slack/slack_client.rb, line 5 def initialize(webhook, options = {}) user = options[:user] || 'cruisecontrol' channel = options[:channel] || '#general' @client = Slack::Notifier.new webhook, channel: channel, username: user end
Public Instance Methods
send_message(mesg, options = {})
click to toggle source
options: See github.com/stevenosloan/slack-notifier , additional parameters
# File lib/cruisecontrolrb-to-slack/slack_client.rb, line 15 def send_message(mesg, options = {}) @client.ping mesg, options end