Module: Rake::TaskManager

Module | Rake::TaskManager
In: | lib/rake.rb

The TaskManager module is a mixin for managing tasks.

### Methods

[] clear create_rule current_scope define_task enhance_with_matching_rule in_namespace intern lookup new resolve_args synthesize_file_task tasks

### Attributes

last_comment | [RW] | Track the last comment made in the Rakefile.

### Public Class methods

new()

### Public Instance methods

[](task_name, scopes=nil)

Find a matching task for `task_name`.

clear()

Clear all tasks in this application.

create_rule(args, &block)
current_scope()

Return the list of scope names currently active in the task manager.

define_task(task_class, args, &block)
enhance_with_matching_rule(task_name, level=0)

If a rule can be found that matches the task name, enhance the task with the prerequisites and actions from the rule. Set the source attribute of the task appropriately for the rule. Return the enhanced task or nil of no rule was found.

in_namespace(name) {|ns| ...}

Evaluate the block in a nested namespace named `name`. Create an anonymous namespace if `name` is nil.

intern(task_class, task_name)

Lookup a task. Return an existing task if found, otherwise create a task of the current type.

lookup(task_name, initial_scope=nil)

Lookup a task, using scope and the scope hints in the task name. This method performs straight lookups without trying to synthesize file tasks or rules. Special scope names (e.g. ’^’) are recognized. If no scope argument is supplied, use the current scope. Return nil if the task cannot be found.

resolve_args(args)

Resolve the arguments for a task/rule.

synthesize_file_task(task_name)
tasks()

List of all defined tasks in this application.

[Validate]