added rubygems for easier command line execution

The script didn't initially run in my environment.

* added require rubygems
* may have gem installed json (can't recall)

Thanks for a useful tool!