-
Notifications
You must be signed in to change notification settings - Fork 6
Development Setup
- Ruby 3.3.4 (use rbenv or asdf)
- PostgreSQL 11+
- Node.js (LTS) with Yarn
-
foremangem:gem install foreman
git clone https://github.com/vgartg/jammer.git
cd jammer
bundle install
yarn install
bundle exec rake db:create
bundle exec rake db:migrateforeman start -f Procfile.devThis starts three processes together: the Rails server, the CSS build watcher, and the JS build watcher. Open localhost:3000.
If you only need to rebuild assets without the server:
foreman start -f Procfile.frontCopy .env.example to .env and fill in what you need. OAuth credentials (GitHub/Google) are optional for local development - the email/password auth works without them.
bundle exec rails testThe test suite uses PostgreSQL. Make sure the test database exists (db:create handles that).
bundle exec rubocop
bundle exec brakeman -q
bundle exec bundler-audit --updateThese are the same checks CI runs. Run them before opening a PR.
In development, emails are intercepted by letter_opener and open as browser tabs instead of actually sending. No mail server needed.
Sidekiq is not started by Procfile.dev. For local testing of background jobs, run it separately:
bundle exec sidekiqOr just call job classes inline from rails console.
-
rails consoleis your friend for poking at models. - The admin panel is at
/admin- you need a user withrole: admin. In development, set it in console:User.first.update(role: :admin). - User subdomains work in development if you add entries to
/etc/hosts(e.g.,127.0.0.1 yourname.localhost), but that's optional.