Install missing gems using the Missing gem inspection provided by the IDE. For example, open the Gemfile, place a caret to any highlighted gem missing in the project SDK and press &shortcut:ShowIntentionActions;.