Rake, Namespaces, and dependencies

S

S. Robert James

I can't figure out the correct syntax in a Rakefile to say that a
certain task depends on a task in a different namespace. What is it?
 
S

S. Robert James

S. Robert James said:
I can't figure out the correct syntax in a Rakefile to say that a
certain task depends on a task in a different namespace. What is it?

If my question isn't clear, please let me know. Is there no way to do
this?
 
S

S. Robert James

S. Robert James said:
I can't figure out the correct syntax in a Rakefile to say that a
certain task depends on a task in a different namespace. What is it?

task :ci => [:rcov_params, namespace:)test)[:rcov] ]
doesn't work
 
M

Mauricio Fernandez

S. Robert James said:
I can't figure out the correct syntax in a Rakefile to say that a
certain task depends on a task in a different namespace. What is it?

task :ci => [:rcov_params, namespace:)test)[:rcov] ]
doesn't work

$ cat Rakefile
namespace :foo do
namespace :bar do
desc "nested baz"
task :baz do
puts "foo:bar:baz"
end
end

desc "outer baz"
task :bar => "foo:bar:baz" do
puts "foo:bar"
end
end
$ rake -T
(in /home/batsman/mess/2006/46)
rake foo:bar # outer baz
rake foo:bar:baz # nested baz
$ rake foo:bar
(in /home/batsman/mess/2006/46)
foo:bar:baz
foo:bar
 
S

S. Robert James

Thanks.

Mauricio said:
S. Robert James said:
I can't figure out the correct syntax in a Rakefile to say that a
certain task depends on a task in a different namespace. What is it?

task :ci => [:rcov_params, namespace:)test)[:rcov] ]
doesn't work

$ cat Rakefile
namespace :foo do
namespace :bar do
desc "nested baz"
task :baz do
puts "foo:bar:baz"
end
end

desc "outer baz"
task :bar => "foo:bar:baz" do
puts "foo:bar"
end
end
$ rake -T
(in /home/batsman/mess/2006/46)
rake foo:bar # outer baz
rake foo:bar:baz # nested baz
$ rake foo:bar
(in /home/batsman/mess/2006/46)
foo:bar:baz
foo:bar
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,767
Messages
2,569,572
Members
45,045
Latest member
DRCM

Latest Threads

Top