It sucks and takes forever, but it should reduce roadblocks in the future.
Install Homebrew
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
brew install git gh heroku/heroku
git config --global user.name "John Doe"
git config --global user.email [email protected]
gh auth login
Decide on some root directory for your code repos. On my personal machine, I use ~/dev/bmd
. On a company machine, it might be something like ~/code
. Create that directory, and inside it, checkout the following repos:
- https://github.com/bwymedia/BMD-Accounts
- https://github.com/bwymedia/StagePlayer-Desktop
- https://github.com/bwymedia/backstage-api
- https://github.com/bwymedia/backstage-web
For this, the GitHub CLI is convenient:
gh repo clone bwymedia/BMD-Accounts
gh repo clone bwymedia/StagePlayer-Desktop
gh repo clone bwymedia/backstage-api
gh repo clone bwymedia/backstage-web
This is an important tool for having multiple versions of Ruby installed. You can read a little about it on their GitHub page, it's helpful to understand the basics of shims and PATH that makes the magic happen. Follow the installation instructions.
Luckily, we don't need the complexity of managing multiple versions of node. Just install node with Homebrew:
brew install node
Inside each repo:
brew bundle
rbenv install
bundle install
bin/rails db:setup
bin/rails c
Explanation:
brew bundle
installs needed system packages, specified in theBrewfile
. For example, the web servers need things likepostgres
orffmpeg
, which are system-wide.rbenv install
installs the specific ruby version needed to run the server. With the correctrbenv
configuration, you should now be able to run ruby commands when inside the repo directory.bundle install
installs Ruby gems (Ruby equivalent of package/library) needed to run the server. For example, the Rails framework is a Ruby gem.bin/rails db:setup
creates a development database in your local Postgres instance.
npm install
npm run dev
Stay tuned...