Skip to content

Instantly share code, notes, and snippets.

@srhyne
Created June 21, 2012 17:14
Show Gist options
  • Save srhyne/2967109 to your computer and use it in GitHub Desktop.
Save srhyne/2967109 to your computer and use it in GitHub Desktop.
Diff last commit on Beanstalk server with local head
#!/usr/bin/env ruby
require 'rubygems'
require 'beanstalkapp'
Beanstalk::API::Base.setup(
:domain => "your_beanstalk_account_subdomain",
:login => "login",
:password => ENV['BEANSTALK_PW']
)
master = Beanstalk::API::ServerEnvironment.find_for_repository(environment_id, "repo");
hash = master.current_version
p "Production on #{hash}"
`git difftool #{hash} head`
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment