From 9d3ade784017711387038bf39a36cb48d1307747 Mon Sep 17 00:00:00 2001 From: Florian Schwab Date: Sun, 11 Feb 2018 10:05:55 +0100 Subject: [PATCH] remove rails 5.2 deprecation for setting environment without '-e' --- CHANGELOG.md | 1 + lib/capistrano/rails/console/tasks.cap | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 103548d..4bf489e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,7 @@ ## Unreleased ### Feature +- remove rails 5.2 deprecation: _Passing the environment's name as a regular argument is deprecated and will be removed in the next Rails version. Please, use the -e option instead._ - allow to set capistrano role to select server for remote console (#33) - allow to set shell used on server (#31) diff --git a/lib/capistrano/rails/console/tasks.cap b/lib/capistrano/rails/console/tasks.cap index f15cc28..20cf752 100644 --- a/lib/capistrano/rails/console/tasks.cap +++ b/lib/capistrano/rails/console/tasks.cap @@ -23,7 +23,7 @@ namespace :rails do run_interactively primary(fetch(:console_role)), shell: fetch(:console_shell) do within current_path do as user: fetch(:console_user) do - execute(:rails, :console, fetch(:console_env), *args) + execute(:rails, :console, '-e', fetch(:console_env), *args) end end end