This is a Ruby on Rails app built to house League and Player information for a Card Baseball Game. The "card" game has since been abandoned, but has been heartfully continued using an Excel file. This app hopes to reproduce the game, but is currently a work in progress.
- Ruby
- rbenv, rvm, or similar
- PostgreSQL
Clone from GitHub and cd into project directory
# install ruby version set in .ruby-version
rbenv install # or `rvm install`
gem install bundler
bundle install --without productionInstall yarn on your system. This step might also install Node.js, but please see below to ensure that you use the right version when working on the project.
I use Node Version Manager to maintain a more consistent Node.js version. The version number is stored in ./.nvmrc. Please use that version of node or use nvm to install it.
# using nvm
# cd into project directory
nvm install
nvm use
# finally, install packages
yarn installEnvironment variables are used to store passwords and tokens. The gem dotenv-rails is used in test and development environments. An example file is included in the repo for an idea of the key options. For production, set variables when running the app.
- Rename
.env.exampleto.envand add the real values
bin/rails db:setupbin/rails rspec spec/I use guard to automate local development
bundle exec guard -g backend # start rspec and bundler watchers
bundle exec guard -g frontend # start server (port 3000) and livereload watcher