From 0b18caccf234f0509fec81bf57b63894564aacc9 Mon Sep 17 00:00:00 2001 From: Stan Lo Date: Wed, 15 May 2024 11:31:47 +0900 Subject: [PATCH] Add app.rb and helpers.rb back Those files were removed in #51760, but gems like `console1984` depend on these files for legacy Rails console command extensions. So keeping files around is required for backward-compatibility. --- railties/lib/rails/console/app.rb | 8 ++++++++ railties/lib/rails/console/helpers.rb | 8 ++++++++ 2 files changed, 16 insertions(+) create mode 100644 railties/lib/rails/console/app.rb create mode 100644 railties/lib/rails/console/helpers.rb diff --git a/railties/lib/rails/console/app.rb b/railties/lib/rails/console/app.rb new file mode 100644 index 0000000000000..916601b033d2b --- /dev/null +++ b/railties/lib/rails/console/app.rb @@ -0,0 +1,8 @@ +# frozen_string_literal: true + +ActiveSupport::Deprecation.new.warn(<<~MSG, caller_locations(0..1)) +`rails/console/app.rb` has been deprecated and will be removed in Rails 8.0. +Please require `rails/console/methods.rb` instead. +MSG + +require "rails/console/methods" diff --git a/railties/lib/rails/console/helpers.rb b/railties/lib/rails/console/helpers.rb new file mode 100644 index 0000000000000..472f46dfe7730 --- /dev/null +++ b/railties/lib/rails/console/helpers.rb @@ -0,0 +1,8 @@ +# frozen_string_literal: true + +ActiveSupport::Deprecation.new.warn(<<~MSG, caller_locations(0..1)) +`rails/console/helpers.rb` has been deprecated and will be removed in Rails 8.0. +Please require `rails/console/methods.rb` instead. +MSG + +require "rails/console/methods"