Skip to content
This repository has been archived by the owner on Jan 29, 2021. It is now read-only.

exercism/seeds

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

83 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Seeds

Exercism seed data generator.

Developing locally can be a challenge without data.

Placeholder data is often not varied enough or interesting enough to run into weird edge-cases.

In order to create fake but real-ish data, this project:

  • creates fake users with nice avatars from the uifaces project
  • uses real (random) code examples from exercism.
  • creates fake nitpicks generated from markov chains using real exercism comments.

Usage

At the moment, most of this can only be used if you have access to the a copy of the exercism.io production database.

It also makes a ton of assumptions about database names, usernames, etc.

If you have access, this will fetch and restore a dump:

heroku pgbackups:capture
curl -o latest.dump `heroku pgbackups:url`
pg_restore --verbose --clean --no-acl --no-owner -h localhost -U exercism -d exercism_development latest.dump
echo "UPDATE users SET email=NULL" | psql -d exercism_development

To generate the basic seed data, run:

rake seeds:generate

This creates all the data, using a placeholder for comments.

Generating exercismarkov nitpicks

Extract all the exercism comments to text files:

rake extract:nitpicks

Then get a build of the exercism/arkov project to create the underlying data structures that the nitpicks can be created from:

rake generate:markov

About

Exercism seed data generator

Resources

Code of conduct

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published