cape 1.6.2 → 1.7.0
Sign up to get free protection for your applications and to get access to all the features.
- data/Gemfile +7 -6
- data/Guardfile +29 -10
- data/History.markdown +4 -0
- data/README.markdown +38 -9
- data/Rakefile +35 -8
- data/features/dsl/each_rake_task/{without_arguments.feature → unqualified.feature} +16 -37
- data/features/dsl/each_rake_task/{with_defined_namespace_argument.feature → with_defined_namespace.feature} +2 -13
- data/features/dsl/each_rake_task/{with_defined_task_argument.feature → with_defined_task.feature} +2 -6
- data/features/dsl/each_rake_task/with_undefined_task_or_namespace.feature +24 -0
- data/features/dsl/mirror_rake_tasks/inside_capistrano_namespace.feature +2 -2
- data/features/dsl/mirror_rake_tasks/{without_arguments.feature → unqualified.feature} +15 -11
- data/features/dsl/mirror_rake_tasks/with_cd.feature +63 -0
- data/features/dsl/mirror_rake_tasks/with_cd_and_environment_variables.feature +27 -0
- data/features/dsl/mirror_rake_tasks/{with_defined_namespace_argument.feature → with_defined_namespace.feature} +6 -8
- data/features/dsl/mirror_rake_tasks/{with_defined_task_argument.feature → with_defined_task.feature} +4 -4
- data/features/dsl/mirror_rake_tasks/{with_defined_task_argument_and_environment_variables.feature → with_defined_task_and_cd.feature} +8 -8
- data/features/dsl/mirror_rake_tasks/with_defined_task_and_cd_and_environment_variables.feature +46 -0
- data/features/dsl/mirror_rake_tasks/with_defined_task_and_environment_variables.feature +92 -0
- data/features/dsl/mirror_rake_tasks/with_defined_task_and_rename.feature +47 -0
- data/features/dsl/mirror_rake_tasks/with_defined_task_and_rename_and_cd.feature +49 -0
- data/features/dsl/mirror_rake_tasks/with_defined_task_and_rename_and_cd_and_environment_variables.feature +52 -0
- data/features/dsl/mirror_rake_tasks/with_defined_task_and_rename_and_environment_variables.feature +50 -0
- data/features/dsl/mirror_rake_tasks/with_defined_task_and_rename_and_valid_options.feature +49 -0
- data/features/dsl/mirror_rake_tasks/with_defined_task_and_rename_and_valid_options_and_cd.feature +51 -0
- data/features/dsl/mirror_rake_tasks/with_defined_task_and_rename_and_valid_options_and_cd_and_environment_variables.feature +54 -0
- data/features/dsl/mirror_rake_tasks/with_defined_task_and_rename_and_valid_options_and_environment_variables.feature +52 -0
- data/features/dsl/mirror_rake_tasks/with_defined_task_and_valid_options.feature +53 -6
- data/features/dsl/mirror_rake_tasks/{with_defined_task_and_valid_options_arguments_and_environment_variables.feature → with_defined_task_and_valid_options_and_cd.feature} +10 -8
- data/features/dsl/mirror_rake_tasks/with_defined_task_and_valid_options_and_cd_and_environment_variables.feature +48 -0
- data/features/dsl/mirror_rake_tasks/with_defined_task_and_valid_options_and_environment_variables.feature +98 -0
- data/features/dsl/mirror_rake_tasks/with_environment_variables.feature +61 -4
- data/features/dsl/mirror_rake_tasks/with_rename.feature +27 -0
- data/features/dsl/mirror_rake_tasks/with_rename_and_cd.feature +28 -0
- data/features/dsl/mirror_rake_tasks/with_rename_and_cd_and_environment_variables.feature +30 -0
- data/features/dsl/mirror_rake_tasks/with_rename_and_environment_variables.feature +29 -0
- data/features/dsl/mirror_rake_tasks/with_rename_and_valid_options.feature +28 -0
- data/features/dsl/mirror_rake_tasks/with_rename_and_valid_options_and_cd.feature +29 -0
- data/features/dsl/mirror_rake_tasks/with_rename_and_valid_options_and_cd_and_environment_variables.feature +31 -0
- data/features/dsl/mirror_rake_tasks/with_rename_and_valid_options_and_environment_variables.feature +30 -0
- data/features/dsl/mirror_rake_tasks/{with_undefined_argument.feature → with_undefined_task_or_namespace.feature} +3 -4
- data/features/dsl/mirror_rake_tasks/with_valid_options.feature +46 -0
- data/features/dsl/mirror_rake_tasks/{with_valid_options_argument.feature → with_valid_options_and_cd.feature} +7 -5
- data/features/dsl/mirror_rake_tasks/with_valid_options_and_cd_and_environment_variables.feature +28 -0
- data/features/dsl/mirror_rake_tasks/with_valid_options_and_environment_variables.feature +51 -0
- data/features/dsl/rake_executable.feature +2 -2
- data/features/step_definitions.rb +40 -0
- data/lib/cape.rb +2 -0
- data/lib/cape/capistrano.rb +59 -32
- data/lib/cape/capistrano_deprecated.rb +165 -0
- data/lib/cape/core_ext.rb +2 -0
- data/lib/cape/deprecation.rb +12 -0
- data/lib/cape/deprecation/base.rb +59 -0
- data/lib/cape/deprecation/capistrano_deprecated_define_rake_wrapper.rb +168 -0
- data/lib/cape/deprecation/dsl_deprecated_mirror_rake_tasks.rb +145 -0
- data/lib/cape/dsl.rb +49 -60
- data/lib/cape/dsl_deprecated.rb +157 -0
- data/lib/cape/hash_list.rb +2 -0
- data/lib/cape/recipe_definition.rb +103 -0
- data/lib/cape/recipe_definition_deprecated.rb +41 -0
- data/lib/cape/util.rb +2 -0
- data/lib/cape/version.rb +1 -1
- data/lib/cape/xterm.rb +326 -0
- data/spec/cape/deprecation/base_sharedspec.rb +18 -0
- data/spec/cape/deprecation/capistrano_deprecated_define_rake_wrapper_spec.rb +157 -0
- data/spec/cape/deprecation/dsl_deprecated_mirror_rake_tasks_spec.rb +153 -0
- data/spec/cape/dsl_deprecated_spec.rb +307 -0
- data/spec/cape/dsl_spec.rb +10 -43
- data/spec/cape/recipe_definition_spec.rb +53 -0
- data/spec/cape/xterm_spec.rb +72 -0
- metadata +97 -28
- data/features/dsl/each_rake_task/with_undefined_argument.feature +0 -53
- data/features/dsl/mirror_rake_tasks/with_valid_options_arguments_and_environment_variables.feature +0 -26
data/features/dsl/mirror_rake_tasks/with_valid_options_arguments_and_environment_variables.feature
DELETED
@@ -1,26 +0,0 @@
|
|
1
|
-
Feature: The #mirror_rake_tasks DSL method with an argument of valid options, and with environment variables
|
2
|
-
|
3
|
-
In order to include Rake tasks with descriptions in my Capistrano recipes,
|
4
|
-
As a developer using Cape,
|
5
|
-
I want to use the Cape DSL.
|
6
|
-
|
7
|
-
Scenario: mirror a Rake task with its implementation
|
8
|
-
Given a full-featured Rakefile
|
9
|
-
And a Capfile with:
|
10
|
-
"""
|
11
|
-
set :current_path, '/path/to/current/deployed/application'
|
12
|
-
set :rails_env, 'production'
|
13
|
-
|
14
|
-
Cape do
|
15
|
-
mirror_rake_tasks :roles => :app do |env|
|
16
|
-
env['RAILS_ENV'] = rails_env
|
17
|
-
end
|
18
|
-
end
|
19
|
-
"""
|
20
|
-
When I run `cap with_period`
|
21
|
-
Then the output should contain:
|
22
|
-
"""
|
23
|
-
* executing `with_period'
|
24
|
-
* executing "cd /path/to/current/deployed/application && /usr/bin/env `/usr/bin/env bundle check >/dev/null 2>&1; case $? in 0|1 ) echo bundle exec ;; esac` rake with_period RAILS_ENV=\"production\""
|
25
|
-
`with_period' is only run for servers matching {:roles=>:app}, but no servers matched
|
26
|
-
"""
|