Exceptions, Organization, Examples...

Organized the code a bit. Script to run in /bin code in /lib and examples in /example.

Added Exception handling for unknown variables and id.

Parse XML with Nokogiri and use Xpath to get variables and the attributes, then use simpler regexp to get placeholder.

Added examples.