SeedingUtils

Some Postgres-specific database seeding utilities we use at FlexMinder.

It mainly provides a wrapper around Postgres's COPY functionality to allow you to cache largish seed datasets so that recreating a schema with seed data during early application development is runs more quickly.

In our use case, we need to load US ZIP code and other geolocation data, and our initial data seeding takes 3-5 minutes. With the caching functionality provided by this gem, we reduce that to about 30 seconds.

Installation

Add this line to your application's Gemfile:

gem 'seeding_utils'

And then execute:

$ bundle

Or install it yourself as:

$ gem install seeding_utils

Usage

Contributing

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request