Start Server | Test / Watch |
---|---|
$ bin/rails s |
$ bin/guard |
Dependencies:
- Ruby 2.5.1
- bundler gem (
$ gem install bundler
) - postgres (on OSX, use Postgres.app)
- System dependencies, assuming you are using Homebrew on OSX:
brew bundle
Setup:
- Run
$ bin/setup
- Start the server:
$ bin/rails s
- Visit it in your web browser:
http://localhost:3000
- All tests can be run with
bin/rspec
- File watching can be started with
bin/guard
- Individual tests can be isolated by adding
:focus
to declaration, e.g.it 'runs a test', :focus do
- Within feature specs, the page can be inspected by adding
save_and_open_page
eggshell, fleet
: 1 groupeggshell, van
: 2 groups
- Download the production database locally
$ heroku pg:pull DATABASE_URL panlexicon_production --app panlexicon
- Dump the thesaurus table data:
pg_dump --data-only --no-acl --no-owner \
-h localhost -U $(whoami) -d panlexicon_production \
--table words \
--table groups \
--table groupings \
--table parts_of_speech\
--format tar --file=data.sql.tar
- Upload the data file to the Github-hosted release
- If the downloadable url/filename changed, update the
bin/setup
file
This application uses the public domain Moby Thesaurus to provide words and relations. If you choose not to use the database dump described in the Installation and Setup section, you can manually import it (it takes an hour or two):
- Download the Moby Thesaurus textfile: http://www.gutenberg.org/ebooks/3202
- Import it:
$ rake moby:import_thesaurus[mthesaur.txt]
(assuming the unzipped thesaurus file is sitting in your rails root namedmthesaur.txt
)