From 3b1fb04e193c422c6fdff870a2d5f0ddf11415ab 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 c238925b74b..7f755cf5975 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 \