From c731420098f91cd46dbdd5725b273a07dbea2e81 Mon Sep 17 00:00:00 2001 From: Elia Schito Date: Wed, 13 Dec 2023 17:57:41 +0100 Subject: [PATCH] Generate the sandbox using the version of Rails coming from the Gemfile (cherry picked from commit cb1aaba14b3ccd6d0b2eafcb53486bdef3a131c5) --- bin/sandbox | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/bin/sandbox b/bin/sandbox index ebff817bc09..c103ea21354 100755 --- a/bin/sandbox +++ b/bin/sandbox @@ -41,7 +41,8 @@ echo "~~~> Removing the old sandbox" rm -rf ./sandbox echo "~~~> Creating a pristine Rails app" -rails new sandbox \ +rails_version=`bundle exec ruby -e'require "rails"; puts Rails.version'` +rails _${rails_version}_ new sandbox \ --database="$RAILSDB" \ --skip-git \ --skip-keeps \