Skip to content

How to skip warning prompts when calling another task? #2276

@thetillhoff

Description

@thetillhoff

Description

In the docs, it's stated that a prompt can be skipped with --yes.
Is this also possible when calling another task with task: taskname?
If yes, how?

Version

3.43.3

Operating system

macOS

Experiments Enabled

No response

Example Taskfile

# https://taskfile.dev

version: '3'

tasks:
  foo:
    cmds:
      - for:
          var: CLI_ARGS
        task: bar
        vars:
          CLI_ARGS: '{{ .ITEM }}'

  bar:
    internal: true
    prompt: Are you sure?
    cmds:
      - echo 'Hello world'
    vars:
      CLI_ARGS: '{{ .CLI_ARGS }}'

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