Permalink
Browse files

Introduce new configuration "composer_working_dir" to override the di…

…rectory composer is working on
  • Loading branch information...
1 parent a936728 commit 1d898fd445dc860be8b7bee676204785d6af5575 Michael Feinbier committed with michaelfeinbier Oct 20, 2014
Showing with 3 additions and 1 deletion.
  1. +1 −0 README.md
  2. +2 −1 lib/capistrano/tasks/composer.rake
View
@@ -52,6 +52,7 @@ Configurable options, shown here with defaults:
```ruby
set :composer_install_flags, '--no-dev --no-interaction --quiet --optimize-autoloader'
set :composer_roles, :all
+set :composer_working_dir, -> { fetch(:release_path) }
set :composer_dump_autoload_flags, '--optimize'
set :composer_download_url, "https://getcomposer.org/installer"
set :composer_version, '1.0.0-alpha8' #(default: not set)
@@ -23,7 +23,7 @@ namespace :composer do
task :run, :command do |t, args|
args.with_defaults(:command => :list)
on release_roles(fetch(:composer_roles)) do
- within release_path do
+ within fetch(:composer_working_dir) do
execute :composer, args[:command], *args.extras
end
end
@@ -64,6 +64,7 @@ namespace :load do
task :defaults do
set :composer_install_flags, '--no-dev --prefer-dist --no-interaction --quiet --optimize-autoloader'
set :composer_roles, :all
+ set :composer_working_dir, -> { fetch(:release_path) }
set :composer_dump_autoload_flags, '--optimize'
set :composer_download_url, "https://getcomposer.org/installer"
end

0 comments on commit 1d898fd

Please sign in to comment.