Skip to content

Commit

Permalink
[TT-9423] Add godoc taskfile (#5303)
Browse files Browse the repository at this point in the history
https://tyktech.atlassian.net/browse/TT-9423

Run it with task -t `.taskfiles/godoc/Taskfile.yml`, or go into
`.taskfiles/godoc` and run `task`.

Co-authored-by: Tit Petric <tit@tyk.io>
  • Loading branch information
titpetric and Tit Petric authored Jul 11, 2023
1 parent 9f5f47d commit 4def67e
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions .taskfiles/godoc/Taskfile.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
---
version: "3"

tasks:
default:
desc: "Run godoc on all packages"
dir: ../..
vars:
package:
sh: go list .
packages:
sh: go list ./... | sed -e 's|{{.package}}|.|g'
silent: true
cmds:
- |
set -e;
{{- range $i, $package := .packages | splitLines -}}
go doc {{ $package }}
{{ end -}}

0 comments on commit 4def67e

Please sign in to comment.