Skip to content

Instantly share code, notes, and snippets.

View maxshelley's full-sized avatar

Max Shelley maxshelley

View GitHub Profile
require 'dnsimple'
require 'platform-api'
namespace :staging do
desc "create subdomain DNS record for Heroku review app"
task :publish_dns do
heroku_app_name = ENV['HEROKU_APP_NAME']
heroku_app_name =~ /.*(pr-\d+)/
subdomain = $1