Skip to content

Instantly share code, notes, and snippets.

#!/usr/bin/env ruby
require 'rubygems'
require 'mechanize'
require 'optparse'
options = {}
op = OptionParser.new do |opts|
opts.on('-f=FILE', '--file=FILE', "Write output to specified file.") do |f|
options[:file] = f
@mhl
mhl / meld-compare-refs.py
Created July 29, 2010 16:46
Extract the trees from two commits to a temporary directory and run meld on them
#!/usr/bin/python3.1
# This is script that extracts the trees of two commits to temporary
# directories and then runs meld on both directories, so you can compare
# them using meld's nice recursive browsing interface.
#
# This is for an answer to this question:
# http://stackoverflow.com/questions/2006032/view-differences-of-branches-with-meld
from subprocess import call, Popen, PIPE, check_call