Skip to content

Instantly share code, notes, and snippets.

@asonas
Last active Dec 24, 2015
Embed
What would you like to do?
after "deploy", "deploy:notify_revision"
namespace :deploy do
task :notify_revision do
user_name = `git config --global user.name`.gsub("\n", '')
github_path = "https://github.com/asonas/asonas.jp/commit/#{current_revision}"
body = "#{user_name} deployed a new version of plife (#{current_revision[0...8]}) #{github_path}"
idobata_hook_url = "https://idobata.io/hook/xxxxx-xxxxx-xxxxx" # Room Settings > Manage hooks
run "curl #{idobata_hook_url} -d 'body=#{body}'"
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment