New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

make rake proxy work in rails engines #23169

Merged
merged 1 commit into from Jan 31, 2016

Conversation

Projects
None yet
5 participants
@y-yagi
Member

y-yagi commented Jan 21, 2016

To avoid confusion, even Rails engines, I think that it may be able to run the rake task over the rails command. How about?

@rails-bot

This comment has been minimized.

rails-bot commented Jan 21, 2016

r? @matthewd

(@rails-bot has picked a reviewer for you, use r? to override)

@maclover7

This comment has been minimized.

Member

maclover7 commented Jan 21, 2016

cc @kaspth

@kaspth

View changes

railties/lib/rails/engine/rake_proxy.rb Outdated
end
end
end
end

This comment has been minimized.

@kaspth

kaspth Jan 24, 2016

Member

Why can't we reuse the proxy from main Rails?

This comment has been minimized.

@y-yagi

y-yagi Jan 26, 2016

Member

I thought too much or reuse, but it is almost the same when the review.
I'm sorry, and then modified to reuse the rake_proxy of Rails.

This comment has been minimized.

@y-yagi

y-yagi Jan 26, 2016

Member

Updated.

@y-yagi y-yagi force-pushed the y-yagi:rake_proxy_in_engine branch 3 times, most recently Jan 26, 2016

@kaspth

View changes

railties/CHANGELOG.md Outdated
* Make rake proxy work in Rails engines.
*Yuji Yaginuma*

This comment has been minimized.

@kaspth

kaspth Jan 30, 2016

Member

Don't think this is CHANGELOG worthy, let's assume it worked in engines always.

This comment has been minimized.

@y-yagi

y-yagi Jan 31, 2016

Member

Okay.

@@ -0,0 +1,116 @@
require 'rails/commands/rake_proxy'

This comment has been minimized.

@kaspth

kaspth Jan 30, 2016

Member

Needs to require rake too, no?

This comment has been minimized.

@y-yagi

y-yagi Jan 31, 2016

Member

Has require a rake in the rails/commands/rake_proxy, I think here that it is not need.

@kaspth kaspth assigned kaspth and unassigned matthewd Jan 30, 2016

@kaspth

This comment has been minimized.

Member

kaspth commented Jan 30, 2016

Please rebase and squash your commits too 😁

@kaspth kaspth added this to the 5.0.0 milestone Jan 30, 2016

Rake.application.init('rails')
Rake.application.load_rakefile
@rake_tasks = Rake.application.tasks.select(&:comment)
end

This comment has been minimized.

@kaspth

kaspth Jan 30, 2016

Member

Isn't rake_tasks included from the Rails::RakeProxy?

This comment has been minimized.

@y-yagi

y-yagi Jan 31, 2016

Member

Rails::RakeProxy#rake_tasks has become a prerequisite of the code that uses the Rails application, did not work for as it is the case of the Rails Engine, it was defined separately.

@y-yagi y-yagi force-pushed the y-yagi:rake_proxy_in_engine branch to 3ffa5a1 Jan 31, 2016

@y-yagi

This comment has been minimized.

Member

y-yagi commented Jan 31, 2016

Thanks for reviewing! Rebase and squash commits :)

kaspth added a commit that referenced this pull request Jan 31, 2016

Merge pull request #23169 from y-yagi/rake_proxy_in_engine
make rake proxy work in rails engines

@kaspth kaspth merged commit 81052c8 into rails:master Jan 31, 2016

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details
@kaspth

This comment has been minimized.

Member

kaspth commented Jan 31, 2016

Thanks!

1 similar comment
@y-yagi

This comment has been minimized.

Member

y-yagi commented Jan 31, 2016

Thanks!

@y-yagi y-yagi deleted the y-yagi:rake_proxy_in_engine branch Jan 31, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment