Last active
August 29, 2015 14:06
-
-
Save kidach1/797b0ebdd2f4cd8c754a to your computer and use it in GitHub Desktop.
コード1行でBotがSlackへ通知してくれるGemを公開しました ref: http://qiita.com/kidachi_/items/debfd0474d0888e5b1f1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Call me anywhere | |
SlackBot.notify |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Call me anywhere | |
SlackBot.notify |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SlackBot.notify( | |
body: 'Custom body!', | |
bot_name: 'CustomBot', | |
channel: 'custom-channel' | |
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#Call me anywhere | |
SlackBot.notify( | |
body: "[#{Rails.env}] Custom body!", | |
bot_name: "CustomBot" | |
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SlackBot.setup do |config| | |
config.token = <YOUR_API_TOKEN> | |
config.channel = <YOUR_CHANNEL_OR_GROUPE_NAME> | |
config.bot_name = <BOT_NAME> | |
config.message = <DEFAULT_MESSAGE> | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SlackBot.setup do |config| | |
config.token = xxxxxx | |
config.channel = '#sample-channel' | |
config.bot_name = 'SlackBot' | |
config.body = "[#{Rails.env}] Hello, SlackBot!" | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SlackBot.setup do |config| | |
config.token = xxxxxx | |
config.channel = '#sample-channel' | |
config.bot_name = 'SlackBot' | |
config.body = "[#{Rails.env}] Hello, SlackBot!" | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SlackBot.setup do |config| | |
config.token = xxxxxx | |
config.channel = '#sample-channel' | |
config.bot_name = 'SlackBot' | |
config.body = "[#{Rails.env}] Hello, SlackBot!" | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment