diff --git a/CHANGELOG.md b/CHANGELOG.md index ff399936..70350769 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -13,6 +13,7 @@ gem "capistrano", :github => "capistrano/capistrano" https://github.com/capistrano/capistrano/compare/v3.7.2...HEAD * Your contribution here! +* [#1867](https://github.com/capistrano/capistrano/pull/1867): Allow `cap -T` to run without Capfile present - [@mattbrictson](https://github.com/mattbrictson) ## `3.8.0` (2017-03-10) diff --git a/features/installation.feature b/features/installation.feature index 60fca09c..47574262 100644 --- a/features/installation.feature +++ b/features/installation.feature @@ -3,6 +3,11 @@ Feature: Installation Background: Given a test app without any configuration + Scenario: The "install" task documentation can be viewed + When I run "cap -T" + Then the task is successful + And contains "cap install" in the output + Scenario: With default stages When I run "cap install" Then the deploy.rb file is created diff --git a/lib/capistrano/application.rb b/lib/capistrano/application.rb index d1423e14..101a6090 100644 --- a/lib/capistrano/application.rb +++ b/lib/capistrano/application.rb @@ -96,7 +96,7 @@ module Capistrano end def load_imports - if options.show_tasks + if options.show_tasks && Rake::Task.task_defined?("load:defaults") invoke "load:defaults" set(:stage, "") Dir[deploy_config_path].each { |f| add_import f }