This tool extracts the 'word/document.xml' file from a .docx Zip archive and pretty prints the "beautified" version of the XML to standard out.
This script works with 'ruby-2.0.0-p598' installed via RVM
$bundle install
$ ./XMLExtract.rb input.docx > document.xml