lib/tap/support/gems/rake.rb in bahuvrihi-tap-0.10.8 vs lib/tap/support/gems/rake.rb in bahuvrihi-tap-0.11.0
- old
+ new
@@ -19,10 +19,27 @@
base.env = Tap::Env.instance
end
attr_accessor :env
+ def enq_top_level(app)
+ # takes the place of rake.top_level
+ if options.show_tasks
+ display_tasks_and_comments
+ exit
+ elsif options.show_prereqs
+ display_prerequisites
+ exit
+ else
+ top_level_tasks.each do |task_string|
+ name, args = parse_task_string(task_string)
+ task = self[name]
+ app.mq(task, :invoke, *args)
+ end
+ end
+ end
+
def collect_tasks(*args)
# a little song and dance for compliance with
# rake pre- and post-0.8.2
argv = args.empty? ? ARGV : args[0]
argv.collect! do |arg|
@@ -87,7 +104,8 @@
end
end
end
Rake.application.extend Tap::Support::Gems::Rake
-Tap::Env.manifests[:rakefiles] = Tap::Support::Gems::RakeManifest
-
+Tap::Env.manifest(:rakefiles) do |env|
+ Tap::Support::Gems::RakeManifest.new(env)
+end