Skip to content

Allow default values when args is empty #259

@piranna

Description

@piranna

npm-run-all/lib/index.js

Lines 51 to 56 in bf91f94

if (id === "@") {
return shellQuote.quote(args)
}
if (id === "*") {
return shellQuote.quote([args.join(" ")])
}

If we have a variable expansion with @ or *, we are expanding it unconditionally to the provided args, also if they are empty (no elements array or empty string, respectively), while in that case POSIX variable expansion take the provided default values, if any.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions