Let's integrate Homebrew into our Ruby on Rails Project local set up.
There is a convention for Ruby on Rails projects to use
bin/setup to set up and install/update required dependencies. But by default, it does not include system dependencies.
We are going to use the Homebrew Bundle tool for this.
First, we need to have a
bin/setup, we are going to add:
puts "== Installing system dependencies ==" if system('[[ (-x "$(command -v brew)") ]]') # Is Homebrew available? system("brew bundle check --no-lock --no-upgrade") || system!("brew bundle --no-upgrade --no-lock") # install if there are missed dependencies end
I prefer to add it in the beginning before installing other dependencies.
These will help new onboarding set up development with one command only. Reduces the number of instructions from
If you enjoyed this story, we recommend reading our latest tech stories and trending tech stories.