Monday, April 21, 2008

Harvesting Fixtures from a Live Rails project

So I've put together a simple plugin for grabbing fixtures out of a Live Rails project.


Harvixture is a tool that can be used to extract data, in the form of fixtures,
from a Rails project. It is done by pointing the harvixture at a request_path
and dumping fixtures for all "found" ActiveRecord objects.

$ sudo gem install jeremyf-harvixture --source=http://gems.github.com/

$ cd path/to/rails/project

$ . harvixture run --request_path=/users/1/calendars./bug_100/users.yml
./bug_100/calendars.yml


Get the plugin here.
http://github.com/jeremyf/harvixture/tree/master

TODO:
- Possibly convert to a gem.

No comments: