From 7e41233d76fec0aca6877b62b876b7e2c9b85ec0 Mon Sep 17 00:00:00 2001 From: Kir Shatrov Date: Thu, 23 Jan 2014 11:07:13 +0400 Subject: [PATCH] Using `.rake` extension instead of `.cap` In tests and default templates --- features/step_definitions/setup.rb | 6 +++--- lib/capistrano/templates/Capfile | 2 +- spec/support/tasks/{database.cap => database.rake} | 0 spec/support/tasks/{fail.cap => fail.rake} | 0 spec/support/tasks/{failed.cap => failed.rake} | 0 5 files changed, 4 insertions(+), 4 deletions(-) rename spec/support/tasks/{database.cap => database.rake} (100%) rename spec/support/tasks/{fail.cap => fail.rake} (100%) rename spec/support/tasks/{failed.cap => failed.rake} (100%) diff --git a/features/step_definitions/setup.rb b/features/step_definitions/setup.rb index 16fabc2e..ca53238e 100644 --- a/features/step_definitions/setup.rb +++ b/features/step_definitions/setup.rb @@ -20,7 +20,7 @@ Given(/^the file does not exist$/) do end Given(/^a custom task to generate a file$/) do - TestApp.copy_task_to_test_app('spec/support/tasks/database.cap') + TestApp.copy_task_to_test_app('spec/support/tasks/database.rake') end Given(/^the configuration is in a custom location$/) do @@ -29,10 +29,10 @@ end Given(/^a custom task that will simulate a failure$/) do safely_remove_file(TestApp.shared_path.join('failed')) - TestApp.copy_task_to_test_app('spec/support/tasks/fail.cap') + TestApp.copy_task_to_test_app('spec/support/tasks/fail.rake') end Given(/^a custom task to run in the event of a failure$/) do safely_remove_file(TestApp.shared_path.join('failed')) - TestApp.copy_task_to_test_app('spec/support/tasks/failed.cap') + TestApp.copy_task_to_test_app('spec/support/tasks/failed.rake') end diff --git a/lib/capistrano/templates/Capfile b/lib/capistrano/templates/Capfile index e06ec16d..080238a9 100644 --- a/lib/capistrano/templates/Capfile +++ b/lib/capistrano/templates/Capfile @@ -22,4 +22,4 @@ require 'capistrano/deploy' # require 'capistrano/rails/migrations' # Loads custom tasks from `lib/capistrano/tasks' if you have any defined. -Dir.glob('lib/capistrano/tasks/*.cap').each { |r| import r } +Dir.glob('lib/capistrano/tasks/*.rake').each { |r| import r } diff --git a/spec/support/tasks/database.cap b/spec/support/tasks/database.rake similarity index 100% rename from spec/support/tasks/database.cap rename to spec/support/tasks/database.rake diff --git a/spec/support/tasks/fail.cap b/spec/support/tasks/fail.rake similarity index 100% rename from spec/support/tasks/fail.cap rename to spec/support/tasks/fail.rake diff --git a/spec/support/tasks/failed.cap b/spec/support/tasks/failed.rake similarity index 100% rename from spec/support/tasks/failed.cap rename to spec/support/tasks/failed.rake