1
0
mirror of https://github.com/go-task/task.git synced 2026-04-24 19:54:16 +02:00
Commit Graph

2725 Commits

Author SHA1 Message Date
Valentin Maerten b8abadb4f0 🐛 fix(output): wrap gitlab sections at task level (#2806)
Previously the gitlab output wrapped each command individually, causing
two visible bugs in real GitLab pipelines:

- every section displayed a duration of 00:00, because start and end
  markers were emitted microseconds apart for instant commands
- the `task: [NAME] CMD` announcement lines were rendered outside the
  sections, because Logger.Errf bypassed the cmd-level wrapper

Fix by wrapping output at the task level via a new optional
[output.TaskWrapper] interface that GitLab implements. Task-scoped
writers are threaded via ctx so nested `task:` invocations produce
properly nested sections (GitLab supports this natively), and deps
running in parallel each get their own buffer with mutex-protected
flushes into the parent's buffer.

- `internal/output/output.go`: add TaskWrapper interface
- `internal/output/gitlab.go`: logic moved from WrapWriter to WrapTask;
  WrapWriter becomes passthrough; sync.Mutex around the buffer for
  concurrent flushes from parallel sub-task sections
- `task_output.go` (new): ctx plumbing + helpers kept out of task.go
- `task.go`: 7 lines of surgical edits — name the lambda's error
  return, wrap before the cmd loop, defer the closer with the final
  error, and swap the cmd announcement to `printCmdAnnouncement` which
  writes into the task-scoped stderr
2026-04-22 17:22:54 +02:00
Valentin Maerten 542fe465e9 feat(output): add gitlab output mode (#2806)
Adds a new `gitlab` output style that wraps each task's output in GitLab
CI collapsible section markers. Section IDs are generated automatically
so that start and end markers always match and stay unique per
invocation — even when the same task runs multiple times in one job.

Options: `collapsed` (maps to GitLab's native `[collapsed=true]`) and
`error_only` (Task-level behavior, identical to `group.error_only`).

Also introduces `output-ci-auto` (taskrc + TASK_OUTPUT_CI_AUTO env var)
that auto-selects a CI-aware output style when a supported CI runner is
detected (currently `GITLAB_CI=true` → gitlab) and no output style is
explicitly configured. Keeps the Taskfile neutral so local devs are not
forced into CI-shaped output.

Refs #2806.
2026-04-22 14:10:55 +02:00
Andreas **Felix** Häberle 70b6cd8ee0 docs: add call internal task within a task example (#2789)
Co-authored-by: Valentin Maerten <maerten.valentin@gmail.com>
2026-04-20 21:58:42 +02:00
Valentin Maerten 1eb5720e7e chore: changelog for #2788 2026-04-20 21:53:50 +02:00
Mateen Anjum 1b06da16f6 feat(templater): add absPath template function (#2788)
Signed-off-by: Mateen Anjum <mateenali66@gmail.com>
Co-authored-by: Valentin Maerten <maerten.valentin@gmail.com>
2026-04-20 21:50:03 +02:00
Andrey Nering 6e37e3d7a7 chore(website): remove controls to copy page content
This is part of the LLM plugin. It's distracting and not really useful.

We're keeping the markdown version of the pages, tho. Just append `.md`
to any page to see the markdown version.
2026-04-15 16:39:20 -03:00
Pete Davison 4bea638b05 feat: add security docs to website and update contributing (#2799) 2026-04-15 20:34:38 +01:00
Pete Davison 8f2d17a387 feat: use GH_PAT for goreleaser (#2797) 2026-04-15 13:33:57 +00:00
Andrey Nering f7d17fffad chore(website): update my bluesky handle 2026-04-15 10:16:02 -03:00
Pete Davison 697ef35303 feat: add permissions to actions (#2796) 2026-04-15 13:27:23 +01:00
Andrey Nering 8fe3d048fa docs: document and add blog post about go tool task (#2791) 2026-04-14 22:47:45 -03:00
Andrey Nering d61d92dfdf v3.50.0 v3.50.0 2026-04-13 17:54:26 -03:00
renovate[bot] 114ac1eedc chore(deps): update actions/github-script action to v9 (#2787)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-04-13 10:49:13 -03:00
renovate[bot] a016b7b72b chore(deps): update all non-major dependencies (#2786)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-04-13 10:48:30 -03:00
Andrey Nering 219bf3e5a5 chore: add nolint annotations for gosec linter
Add //nolint:gosec annotations for intentional code patterns
that are safe in context (path traversal in release tool,
uintptr conversion for terminals, weak rand in tests,
TLS skip verify for user-configured insecure mode).

Assisted-by: Kimi-K2.5 via Crush <crush@charm.land>
2026-04-13 10:46:19 -03:00
Andrey Nering b36fcfd8bb chore(golangci-lint): exclude gosec G306 for file permissions
This allows using 0644 file permissions without linter warnings.

Assisted-by: Kimi-K2.5 via Crush <crush@charm.land>
2026-04-13 10:46:19 -03:00
Andrey Nering ef8fb84c8f chore(golangci-lint): enable gosec linter 2026-04-13 10:46:19 -03:00
Andrey Nering ddecd51715 ci: add security action with govulncheck 2026-04-13 10:46:19 -03:00
Andrey Nering 88fc6d4f24 ci: pin action by commit hash 2026-04-13 10:46:19 -03:00
Andrey Nering 07fbd9887e docs(changelog): add entry for #2716 2026-04-11 21:45:48 -03:00
Doug Richardson f2e32beabd fix: re-run task when generated files are missing with method: timestamp (#2716) 2026-04-11 21:42:50 -03:00
dependabot[bot] 8fa9dc04ac chore(deps): bump github.com/aws/aws-sdk-go-v2/service/s3 from 1.97.1 to 1.97.3 (#2778)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-09 06:24:22 +00:00
renovate[bot] 0c98f1ad13 chore(deps): update all non-major dependencies (#2775)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-04-09 06:16:22 +00:00
Valentin Maerten a12cc6e843 chore: changelog for #2764 2026-04-09 08:16:03 +02:00
Mateen Anjum 44e1350d0c fix: handle SIGHUP in watcher (#2764) 2026-04-09 08:15:37 +02:00
dependabot[bot] 2973dd75f9 chore(deps): bump go.opentelemetry.io/otel/sdk from 1.40.0 to 1.43.0 (#2779)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-09 08:07:58 +02:00
dependabot[bot] a10f1d2ee7 chore(deps): bump google.golang.org/grpc from 1.78.0 to 1.79.3 (#2750)
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-03 15:02:49 +00:00
dependabot[bot] f727b55fbc chore(deps): bump github.com/go-jose/go-jose/v4 from 4.1.3 to 4.1.4 (#2771)
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-03 11:58:01 -03:00
renovate[bot] 363153cbf3 chore(deps): update pnpm/action-setup action to v5 (#2766)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-04-02 18:59:00 +02:00
Valentin Maerten 6b436eda48 fix: Windows CI test failures and path normalization (#2670) 2026-03-28 10:39:13 +01:00
Valentin Maerten 2ddebca4e1 docs: add AI usage disclosure policy (#2755) 2026-03-28 10:30:54 +01:00
renovate[bot] b6ab6153a2 chore(deps): update all non-major dependencies (#2728)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-03-28 10:28:52 +01:00
Rohan Santhosh Kumar bca99520bf docs: use dependent in gentle force docs (#2756)
Co-authored-by: rohan436 <rohan.santhoshkumar@googlemail.com>
2026-03-28 10:24:36 +01:00
Pete Davison 1312ee8a81 fix: typo in workflow 2026-03-23 20:06:17 +00:00
Pete Davison b7cb204f10 feat: test adjustments to issue-experiment workflow 2026-03-23 20:01:06 +00:00
renovate[bot] 921f84157a chore(deps): update go-task/setup-task action to v2 (#2759)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-03-23 08:39:36 +01:00
Valentin Maerten 470ef30f8f chore: changelog for #2730 2026-03-21 11:41:47 +01:00
Sergio 87b12e663e fix(fish): honor GO_TASK_PROGNAME for experiments cache (#2730) 2026-03-21 11:37:51 +01:00
Valentin Maerten e61700f36d chore: changelog for #2678 2026-03-21 11:37:12 +01:00
Valentin Maerten 8b6aca5722 feat(requires): support variable references in enum constraints (#2678) 2026-03-21 11:32:02 +01:00
Sergio 19d8fae5f9 docs: correct stdin Taskfile command example (#2738) 2026-03-18 20:48:57 +00:00
Valentin Maerten c387048f8f feat(website): add APK (Alpine Linux) to official package managers
Add Alpine Linux APK installation instructions via Cloudsmith and move
the Cloudsmith hosting info block above the package manager sections.
2026-03-18 21:42:17 +01:00
Valentin Maerten f2b3ba1263 feat(website): add community sponsors section with Cloudsmith (#2748) 2026-03-17 22:00:48 +01:00
renovate[bot] 2139e32426 chore(deps): update dependency netlify-cli to v24 (#2729)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-03-17 21:51:27 +01:00
renovate[bot] d4e168128b chore(deps): update pnpm/action-setup digest to fc06bc1 (#2744)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-03-17 21:51:01 +01:00
Andrey Nering 54bdcba369 ci: update to go 1.26 (#2724) 2026-03-08 17:25:37 -03:00
Andrey Nering c55c969474 docs: update changelog 2026-03-08 17:11:49 -03:00
Andrey Nering 73f9879421 docs: bring back line commented out by mistake 2026-03-08 17:05:32 -03:00
Andrey Nering aa83651da2 v3.49.1 v3.49.1 2026-03-08 17:01:25 -03:00
Andrey Nering 4ddad9f9f7 Revert "fix: Call ReplaceVars() to resolve Ref's for imported global vars." (#2723) 2026-03-08 20:00:12 +00:00