version: '3'

vars:
  TASKFILE_DIR:
    sh: basename $(pwd)

tasks:
  from-included-taskfile:
    cmds:
      - echo '{{.TASKFILE_DIR}}' > from_included_taskfile.txt
    silent: true

  from-included-taskfile-task:
    cmds:
      - echo '{{.TASKFILE_TASK_DIR}}' > from_included_taskfile_task.txt
    silent: true
    vars:
      TASKFILE_TASK_DIR:
        sh: basename $(pwd)
