Skip to content

{{.CLI_ARGS}} is templated as an array instead of string. #2190

@romnn

Description

@romnn

Description

Consider this taskfile.yaml:

# yaml-language-server: $schema=https://taskfile.dev/schema.json
version: "3"
tasks:
  test:
    cmds:
      - 'echo "arguments: {{.CLI_ARGS}}"'

Before v3.43.1 this would print:

"arguments: "

Now it prints:

"arguments: []"

In my taskfiles, I used to always append {{.CLI_ARGS}} to a command such that users may add more arguments via --. Now this would need some sort of concatenation which I'm not sure how to achieve.

Is this expected behaviour or a regression?

Best, Roman

Version

3.43.1

Operating system

MacOS

Experiments Enabled

No response

Example Taskfile

# yaml-language-server: $schema=https://taskfile.dev/schema.json
version: "3"
tasks:
  test:
    cmds:
      - 'echo "arguments: {{.CLI_ARGS}}"'

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions