Rake question: How to call a task from a different namespace

How does one call from inside a namespace, a task from another namespace?

namespace :foo do
   task :a do
     puts "Hello from task a!"
   end
end

namespace :bar do
   task :b do
  Rake::Task[:foo][:a] # How to call foo:a ???
   end
end

Thanks!

   ~Wayne

s///g
Wayne E. Seguin
Sr. Systems Architect & Systems Administrator

Rake::Task['foo:a'].invoke

#invoke will only run a task once. If you want to force it to run (minus any prerequisites) call #execute.

···

On Aug 20, 2007, at 12:48, Wayne E. Seguin wrote:

How does one call from inside a namespace, a task from another namespace?

namespace :foo do
  task :a do
    puts "Hello from task a!"
  end
end

namespace :bar do
  task :b do
  Rake::Task[:foo][:a] # How to call foo:a ???
  end
end

--
Poor workers blame their tools. Good workers build better tools. The
best workers get their tools to do the work for them. -- Syndicate Wars

Thank you kindly!

   ~Wayne

s///g
Wayne E. Seguin
Sr. Systems Architect & Systems Administrator

···

On Aug 20, 2007, at 16:44 , Eric Hodel wrote:

Rake::Task['foo:a'].invoke

#invoke will only run a task once. If you want to force it to run (minus any prerequisites) call #execute.