#2169·capistrano

Deprecation warning emitted even if Capfile has included scm plugin

Author: ninkibahCreated Aug 27, 2025Updated Aug 29, 2025

When I run

bin/cap --dry-run production deploy

I get the following warning at the start:

[Deprecation Notice] `set :scm, :git` is deprecated.
To ensure your project is compatible with future versions of Capistrano,
remove the :scm setting and instead add these lines to your Capfile after
`require "capistrano/deploy"`:

    require "capistrano/scm/git"
    install_plugin Capistrano::SCM::Git

However, my Capfile already has these lines in it.

capfile
# Load DSL and set up stages
require "capistrano/setup"

# Includes default deployment tasks
require "capistrano/deploy"
require "capistrano/scm/git"
install_plugin Capistrano::SCM::Git

# Includes tasks from other gems included in your Gemfile
require "capistrano/bundler"
require "capistrano/rails/assets"
require "capistrano/rails/migrations"

require "capistrano/maintenance"
require "capistrano/rvm"

# Load custom tasks from `lib/capistrano/tasks` if you have any defined
Dir.glob("lib/capistrano/tasks/*.rake").each { |r| import r }

This is frustrating, and I believe I shouldn't receive any warning.

It would appear the problem is caused by the code in lib/capistrano/configuration/scm_resolver.rb in the resolve method.