Skip to content

star globs do not work in generates attribute #2301

Open
@superg

Description

@superg

Description

I am working on setting up a task that generates sqlc source code.
According to documentation in https://taskfile.dev/reference/schema/#task, generates attribute supports star globs when using timestamp method, however this is not what I observe.
First generation with task sqlc creates output files in output. After deleting any file that matches output/*.sql.go, for example output/asdf.sql.go and rerunning task sqlc, the file is not getting regenerated. When instead of star glob I enumerate all output files manually, task sqlc works as expected but it's impractical for my case where a have a lot of files.

Expected:

task sqlc
task: [sqlc] sqlc generate -f sqlc.yaml

Happened:

task sqlc
task: Task "sqlc" is up to date

Version

v3.39.2 (h1:Zt7KXHmMNq5xWZ1ihphDb+n2zYLCo4BdRe09AnMMIgA=)

Operating system

Ubuntu 24.04

Experiments Enabled

No response

Example Taskfile

version: '3'

tasks:
  sqlc:
    method: timestamp
    sources:
      - sqlc.yaml
      - sqlc/*.sql
    generates:
      - output/*.sql.go
    cmds:
      - sqlc generate -f sqlc.yaml

Metadata

Metadata

Assignees

No one assigned

    Labels

    area: fingerprintingChanges related to checksums and caching.

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions