Skip to content

Accessing @copy_from_path inside "from" block #16

Open
ahx opened this Issue Feb 21, 2013 · 1 comment

2 participants

@ahx
ahx commented Feb 21, 2013

Hi. I am using vendorer to builld and update Ember.js:

  from 'git://github.com/emberjs/ember.js.git' do
    puts "Building Ember..."
    Bundler.with_clean_env do
      `cd #{@copy_from_path} && bundle && bundle exec rake dist`
    end
    file 'ember.js', 'dist/ember.js'
    file 'ember.prod.js', 'dist/ember.prod.js'
  end

This basically works and might be useful to others, but accessing @copy_from_path directly feels sneaky.
What do you think about passing it to the block inside the "from" method yield(@copy_from_path?

So that i could write:

  from 'myrepo.git' do |path|
    `mess with #{path}`
    ...
   end
@grosser
Owner
grosser commented Feb 21, 2013

Sounds good and would be consistent to the way file handling works!
Can you make that a pull ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.