From 51fe199a3965fada5d4a0a3cfed53ceb3ff7c377 Mon Sep 17 00:00:00 2001 From: Tom Chauveau Date: Thu, 24 Jun 2021 21:01:49 +0200 Subject: [PATCH] Update doc generator to ignore tests directory Signed-off-by: Tom Chauveau --- cmd/dagger/cmd/doc.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/cmd/dagger/cmd/doc.go b/cmd/dagger/cmd/doc.go index c6c1eda6..765ed609 100644 --- a/cmd/dagger/cmd/doc.go +++ b/cmd/dagger/cmd/doc.go @@ -337,6 +337,11 @@ func walkStdlib(ctx context.Context, output, format string) { return nil } + // Ignore tests directories + if strings.Contains(p, "tests") { + return nil + } + pkgName := fmt.Sprintf("alpha.dagger.io/%s", p) lg.Info().Str("package", pkgName).Str("format", format).Msg("generating doc") val, err := loadCode(pkgName)