Skip to content

rule does not accept prereqs with Symbol names #349

Closed
@jasonkarns

Description

@jasonkarns

It is common for non-file-based tasks to be given names as symbols. It is also common to use symbols as the names of prereq tasks. However, when attempting to define a rule which has non-file-based prereqs, rule will not accept Symbols as prereqs.

task :nonfile

rule ".json" => ['%d', :nonfile] do
end

The output is:

rake aborted!
Don't know how to handle rule dependent: :nonfile

The cause of the error is traced to TaskManager where Symbol is not a valid case match.

when String

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions