Skip to content

aYaremchuk/pivorak-web-app

 
 

Repository files navigation

PivorakWebApp

PivorakWebApp

Build Status codecov Code Climate Issue Count

Setup

$ git clone [email protected]:pivorakmeetup/pivorak-web-app.git
$ cd pivorak-web-app
$ rvm use ruby-2.3.1@pivorak --create
$ bundle
$ cp config/database.yml.example config/database.yml

Before database setup you should install Redis. Look install instructions here:

Note! You should have PostgreSQL >= 9.4

$ rails db:setup
$ rails s

Onboarding Instructions

  • Add ssh key to the server
  • Add user to the rollbar
  • Add user to the #web-app Pivorak Slack channel

How to Deploy

cap production deploy

Chat

Join our slack chat! We have special #pivorak-web-app channel for contributors.

Git Branches

Please checkout your new branch from development branch. And use development branch for deployment to production.

Contribution

  1. Detect which issue you want to resolve. Write comment about this and how you supposed to do this.
  2. Fork project (if you don't have permissions to push).
  3. Checkout new branch with name "#{issue_id}-#{add or fix or improve}-#{job-done-description}" (77-add-feature), write tests, write code, compose nice commit message "##{issue-id} commit message text"(#77 Add feature :tada: -> you may use emoji) and push your branch to origin.
  4. Create merge request into development branch, add reviewers.
  5. Thank you!

Layers

Model

Model should containe only data-logic.

  • Processing -> to service/interactor.
  • Complex queries -> to finders
  • Predicates -> to policy.

View

View should be clean as much as possible. Please, use helpers to avoid call methods with some params at template.

Controller

Skinny controller. Only REST. Only 7 allowed actions (index, show, new, create, edit, update, destroy). If you need additional action - extract to new sub-controller

Service

Single responsibility resource action that represents business logic. Only one public method allowed .call. Everething else - to private

Finder

QueryObject.

Policy

Domain predicates store. Knows answers for all questions.

Info

  1. Travis CI
  2. Code Climate CLI

How to report a bug

  1. Go to issue tracker
  2. Add descriptive title
  3. Add steps to reproduce with screenshots
  4. Add label bug
  5. What happens and what you expected to happen
  6. Browser if it is UI related issue

About

Rails App for PivorakMeetup

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Ruby 80.5%
  • HTML 11.1%
  • CSS 6.6%
  • JavaScript 1.8%