Skip to content

hitobito/development

Repository files navigation

Hitobito Development 👩🏽‍💻

New here? Install our docker development setup!

Development

Start developing by editing files locally with your preferred editor in the app/hitobito/* folders. Those directories are mounted inside the containers. So every saved file is instantly available inside the containers.

💡 If you don't know where to begin changing something, have a look at our hitobito cheatsheet in English and German.

Usage

To initialize the hit command, run the following in your console:

bin/dev-env.sh

To start the development environment, run:

hit up

Access hitobito via http://localhost:3000

Get a list of available commands with:

hit help

Running tests

Open a test shell

When using this for the first time, once daily or after assets changed run the prep command:

hit test prep

Get a shell to run core or wagon specs:

hit test

Run desired tests

Either, to run all tests:

rspec

or, to run specific tests:

rspec spec/models/person_spec.rb

HTTP request debugging with pry

For debugging with pry during a HTTP request, you can attach to the running docker container (detach with Ctrl+c):

hit rails attach

Access Development Database

hit db console

Rerunning seeds

Useful when adding new seeds

hit rails seed

Shutdown

🍺 finished work ? execute hit down to shut down all running containers