Moving ruby script into plugin rather than requiring it.