-
Notifications
You must be signed in to change notification settings - Fork 614
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
Allow cleaning namespaces. #58
Comments
I would follow Rake::NameSpace['namespace_name'].clear |
… so I'm for it. Also, there's only one method in Rake that has |
I wrote |
That one is on a namespace :n do
task :t do
puts 'work'
end
end
my_namespace = Rake::Namespace['n'] # namespace "n"
my_task = my_namespace['t'] # task "n:t" This would match |
Great. Looks perfect! |
hey is this already in progress? I just ran into the need for this functionality myself and would be glad to implement it quickly and send a PR if nobody else is working on it |
Rake::Task
class has aclear()
method for removing actions and prerequisites from task. Would it be possible to provide method like this forRake::NameSpace
to remove all tasks?Also, there is no (at least I couldn't find any) method for searching for namespace like
[](task_name)
inRake::Task
. There is[](name)
method in there, but it searches for task in namespace.These two features could enable one to write:
Where
get
is a bad excuse for a method name that returns namespace by name.The text was updated successfully, but these errors were encountered: