Dagger
Search

go

Go CLI surface (build, test, vet, fmt, run, generate, install, mod*, work,
env, version) so downstream pipelines can compose Go workflows without
re-inventing toolchain pinning, cache mounts, and container plumbing.

Toolchain version is pinned via New(version) or inferred from the source's
go.mod `go` directive; falls back to "latest" when no go directive is
found. Every container mounts the shared `go-mod-cache` and
`go-build-cache` Dagger cache volumes.

Installation

dagger install github.com/z5labs/devex/daggerverse/go@a2dcd31837c97808f0699a6d70bb0bd34d97b8ab

Entrypoint

Return Type
Go !
Arguments
NameTypeDefault ValueDescription
versionString -No description provided
Example
dagger -m github.com/z5labs/devex/daggerverse/go@a2dcd31837c97808f0699a6d70bb0bd34d97b8ab call \
func (m *MyModule) Example() *dagger.Go  {
	return dag.
			Go()
}
@function
def example() -> dagger.Go:
	return (
		dag.go()
	)
@func()
example(): Go {
	return dag
		.go()
}

Types

Go 🔗

Go wraps the Go CLI as Dagger functions. Construct via New(); call Container() for the prepared base container, or use the per-CLI helpers (Build, Test, Vet, …) which reuse the same backing container.

version() 🔗

Version is the pinned Go toolchain version (e.g. “1.23”). Empty means infer from the supplied source’s go.mod go directive; falls back to “latest” when no go directive is found.

Return Type
String !
Example
dagger -m github.com/z5labs/devex/daggerverse/go@a2dcd31837c97808f0699a6d70bb0bd34d97b8ab call \
 version
func (m *MyModule) Example(ctx context.Context) string  {
	return dag.
			Go().
			Version(ctx)
}
@function
async def example() -> str:
	return await (
		dag.go()
		.version()
	)
@func()
async example(): Promise<string> {
	return dag
		.go()
		.version()
}

build() 🔗

Build runs go build against the supplied source and returns /out as a *dagger.Directory. pkg defaults to ./...; when output is empty, -o /out/ is used so go build picks names per its own rules (one binary per main package).

Every flag this function can pass is a named input with its own doc comment, so dagger functions describes what each one does to the output. There is deliberately no raw flags []string escape hatch: a bag of strings cannot be validated, cannot be documented per flag, and makes every caller re-learn the same spellings. Container() is the escape hatch for anything not named here — it hands back the prepared container so a caller can run whatever go build invocation it likes.

Return Type
Directory !
Arguments
NameTypeDefault ValueDescription
sourceDirectory !-No description provided
pkgString !"./..."

Package(s) to build, in go build package-list syntax.

artifactNameString -

Name of the artifact written under /out. Empty means -o /out/, which lets go build name each binary after its main package.

Named artifactName rather than output because the Dagger CLI reserves --output/-o for exporting a call’s result: a function parameter called output collides with it, and dagger call build then fails to parse its own flags before it runs anything. Ci.WithBuild’s binaryName dodges the same collision; this one is not always a binary, because buildmode can make it an archive or a shared library.

trimpathBoolean -

Pass -trimpath: strip the build’s local file system paths out of the binary, so the output does not depend on where it was compiled.

stripBoolean -

Pass -ldflags “-s -w”: drop the symbol table and the DWARF debug info. Smaller binary, no usable stack symbolization or debugger.

stamps[String ! ] -

Link-time variable assignments, each importpath.Name=value, rendered as -ldflags "-X importpath.Name=value". This is how a binary learns its own version or commit. Only the first = splits name from value, so a value may itself contain =. An element with no =, or with an empty name, is rejected. The linker silently ignores a stamp naming a variable that does not exist, or one that is not a package-level string.

tags[String ! ] -

Build tags, passed as -tags a,b,c. Selects which //go:build files are compiled in.

platformString -

Target platform as GOOS/GOARCH[/variant], e.g. “linux/arm64”. Sets GOOS and GOARCH for a cross-compile; empty builds for the toolchain container’s own platform. Any variant segment is ignored — GOARM/GOAMD64 are left unset.

disableCgoBoolean -

Set CGO_ENABLED=0. Produces a statically linked binary with no libc dependency, which is what a scratch image needs, at the cost of the cgo-backed net and os/user implementations.

raceBoolean -

Pass -race: link Go’s data-race detector into the output. The binary then reports racing accesses to stderr as it runs, at roughly 2-20x the CPU and 5-10x the memory of an ordinary build — so this is a binary for an integration test, not one to ship.

-race requires cgo, so it cannot be combined with disableCgo (Build rejects that pairing) and it needs a C toolchain for the target: the golang image has one for its own platform, but a cross-compile via platform does not unless the toolchain image provides it.

buildmodeEnum -

Pass -buildmode=: what the linker emits, which for most modes is not an executable. Absent leaves the flag off entirely, so go build picks its own default for the target — an executable for a main package, an archive for the rest. See BuildMode for what each member produces.

Example
dagger -m github.com/z5labs/devex/daggerverse/go@a2dcd31837c97808f0699a6d70bb0bd34d97b8ab call \
 build --source DIR_PATH --pkg string
func (m *MyModule) Example(source *dagger.Directory, pkg string) *dagger.Directory  {
	return dag.
			Go().
			Build(source, pkg)
}
@function
def example(source: dagger.Directory, pkg: str) -> dagger.Directory:
	return (
		dag.go()
		.build(source, pkg)
	)
@func()
example(source: Directory, pkg: string): Directory {
	return dag
		.go()
		.build(source, pkg)
}

ci() 🔗

Ci returns a new pipeline builder bound to the supplied source.

Return Type
Ci !
Arguments
NameTypeDefault ValueDescription
sourceDirectory !-No description provided
Example
dagger -m github.com/z5labs/devex/daggerverse/go@a2dcd31837c97808f0699a6d70bb0bd34d97b8ab call \
 ci --source DIR_PATH
func (m *MyModule) Example(source *dagger.Directory) *dagger.GoCi  {
	return dag.
			Go().
			Ci(source)
}
@function
def example(source: dagger.Directory) -> dagger.GoCi:
	return (
		dag.go()
		.ci(source)
	)
@func()
example(source: Directory): GoCi {
	return dag
		.go()
		.ci(source)
}

container() 🔗

Container returns the prepared base container with go-mod-cache mounted at /go/pkg/mod, go-build-cache mounted at /root/.cache/go-build, source mounted at /src, and the working directory set to /src. Use this as an escape hatch when a Go command isn’t covered by the typed helpers.

The toolchain image is golang: where version comes from New() or, when New(“”) was used, from source/go.mod’s go directive (fallback “latest”). The signature takes ctx + returns error because go.mod inspection requires async I/O.

Return Type
Container !
Arguments
NameTypeDefault ValueDescription
sourceDirectory !-No description provided
Example
dagger -m github.com/z5labs/devex/daggerverse/go@a2dcd31837c97808f0699a6d70bb0bd34d97b8ab call \
 container --source DIR_PATH
func (m *MyModule) Example(source *dagger.Directory) *dagger.Container  {
	return dag.
			Go().
			Container(source)
}
@function
def example(source: dagger.Directory) -> dagger.Container:
	return (
		dag.go()
		.container(source)
	)
@func()
example(source: Directory): Container {
	return dag
		.go()
		.container(source)
}

cycloneDx() 🔗

CycloneDx renders a CycloneDX 1.6 JSON document describing the module graph compiled into binary.

Why 1.6. 1.6 is the current release and the one Dependency-Track, Grype and Trivy consume; it is also the first to model a component’s licence acknowledgement, which is what lets a low-confidence classifier match be published as “declared” rather than silently asserted.

The component set, the versions and the licences are identical to what Spdx emits for the same inputs: both render from one resolution of the graph, so the two documents cannot disagree about what shipped. See Spdx for how the graph is resolved and how licence confidence is handled.

Return Type
File !
Arguments
NameTypeDefault ValueDescription
binaryFile !-

The compiled Go binary the document describes.

sourceDirectory !-

The source tree the binary was built from. Used to resolve the licence of each linked module; never used to enumerate components.

Example
dagger -m github.com/z5labs/devex/daggerverse/go@a2dcd31837c97808f0699a6d70bb0bd34d97b8ab call \
 cyclone-dx --binary file:path --source DIR_PATH
func (m *MyModule) Example(binary *dagger.File, source *dagger.Directory) *dagger.File  {
	return dag.
			Go().
			Cyclonedx(binary, source)
}
@function
def example(binary: dagger.File, source: dagger.Directory) -> dagger.File:
	return (
		dag.go()
		.cyclonedx(binary, source)
	)
@func()
example(binary: File, source: Directory): File {
	return dag
		.go()
		.cycloneDx(binary, source)
}

env() 🔗

Env runs go env in a source-less base container and returns its stdout.

Return Type
String !
Example
dagger -m github.com/z5labs/devex/daggerverse/go@a2dcd31837c97808f0699a6d70bb0bd34d97b8ab call \
 env
func (m *MyModule) Example(ctx context.Context) string  {
	return dag.
			Go().
			Env(ctx)
}
@function
async def example() -> str:
	return await (
		dag.go()
		.env()
	)
@func()
async example(): Promise<string> {
	return dag
		.go()
		.env()
}

fmt() 🔗

Fmt runs gofmt -l -d . against the supplied source. Returns the diff of any unformatted files; non-empty output is also returned as an error so CI fails fast on formatting violations.

Return Type
String !
Arguments
NameTypeDefault ValueDescription
sourceDirectory !-No description provided
Example
dagger -m github.com/z5labs/devex/daggerverse/go@a2dcd31837c97808f0699a6d70bb0bd34d97b8ab call \
 fmt --source DIR_PATH
func (m *MyModule) Example(ctx context.Context, source *dagger.Directory) string  {
	return dag.
			Go().
			Fmt(ctx, source)
}
@function
async def example(source: dagger.Directory) -> str:
	return await (
		dag.go()
		.fmt(source)
	)
@func()
async example(source: Directory): Promise<string> {
	return dag
		.go()
		.fmt(source)
}

generate() 🔗

Generate runs go generate pkg against the supplied source and returns /src after generation. pkg defaults to ./....

Return Type
Directory !
Arguments
NameTypeDefault ValueDescription
sourceDirectory !-No description provided
pkgString !"./..."No description provided
Example
dagger -m github.com/z5labs/devex/daggerverse/go@a2dcd31837c97808f0699a6d70bb0bd34d97b8ab call \
 generate --source DIR_PATH --pkg string
func (m *MyModule) Example(source *dagger.Directory, pkg string) *dagger.Directory  {
	return dag.
			Go().
			Generate(source, pkg)
}
@function
def example(source: dagger.Directory, pkg: str) -> dagger.Directory:
	return (
		dag.go()
		.generate(source, pkg)
	)
@func()
example(source: Directory, pkg: string): Directory {
	return dag
		.go()
		.generate(source, pkg)
}

install() 🔗

Install runs go install pkg in a source-less base container with GOBIN=/out and returns the resulting binary as a *dagger.File. The returned filename is the basename of pkg (with any @version suffix stripped), matching go install’s naming rules.

pkg MUST be pinned to an explicit version (e.g. pkg@v1.2.3 or a commit-hash pseudo-version); @latest and bare paths are rejected. The pin is what makes the result safe to cache across calls within a session — without it, the proxy could resolve different versions on successive invocations.

Return Type
File !
Arguments
NameTypeDefault ValueDescription
pkgString !-No description provided
Example
dagger -m github.com/z5labs/devex/daggerverse/go@a2dcd31837c97808f0699a6d70bb0bd34d97b8ab call \
 install --pkg string
func (m *MyModule) Example(pkg string) *dagger.File  {
	return dag.
			Go().
			Install(pkg)
}
@function
def example(pkg: str) -> dagger.File:
	return (
		dag.go()
		.install(pkg)
	)
@func()
example(pkg: string): File {
	return dag
		.go()
		.install(pkg)
}

modDownload() 🔗

ModDownload runs go mod download against the supplied source.

Return Type
Void !
Arguments
NameTypeDefault ValueDescription
sourceDirectory !-No description provided
Example
dagger -m github.com/z5labs/devex/daggerverse/go@a2dcd31837c97808f0699a6d70bb0bd34d97b8ab call \
 mod-download --source DIR_PATH
func (m *MyModule) Example(ctx context.Context, source *dagger.Directory)   {
	return dag.
			Go().
			Moddownload(ctx, source)
}
@function
async def example(source: dagger.Directory) -> None:
	return await (
		dag.go()
		.moddownload(source)
	)
@func()
async example(source: Directory): Promise<void> {
	return dag
		.go()
		.modDownload(source)
}

modTidy() 🔗

ModTidy runs go mod tidy against the supplied source and returns the updated /src directory.

Return Type
Directory !
Arguments
NameTypeDefault ValueDescription
sourceDirectory !-No description provided
Example
dagger -m github.com/z5labs/devex/daggerverse/go@a2dcd31837c97808f0699a6d70bb0bd34d97b8ab call \
 mod-tidy --source DIR_PATH
func (m *MyModule) Example(source *dagger.Directory) *dagger.Directory  {
	return dag.
			Go().
			Modtidy(source)
}
@function
def example(source: dagger.Directory) -> dagger.Directory:
	return (
		dag.go()
		.modtidy(source)
	)
@func()
example(source: Directory): Directory {
	return dag
		.go()
		.modTidy(source)
}

modVerify() 🔗

ModVerify runs go mod verify against the supplied source.

Return Type
Void !
Arguments
NameTypeDefault ValueDescription
sourceDirectory !-No description provided
Example
dagger -m github.com/z5labs/devex/daggerverse/go@a2dcd31837c97808f0699a6d70bb0bd34d97b8ab call \
 mod-verify --source DIR_PATH
func (m *MyModule) Example(ctx context.Context, source *dagger.Directory)   {
	return dag.
			Go().
			Modverify(ctx, source)
}
@function
async def example(source: dagger.Directory) -> None:
	return await (
		dag.go()
		.modverify(source)
	)
@func()
async example(source: Directory): Promise<void> {
	return dag
		.go()
		.modVerify(source)
}

run() 🔗

Run runs go run pkg [args...] against the supplied source and returns the program’s stdout. pkg is required (a single runnable main package).

Return Type
String !
Arguments
NameTypeDefault ValueDescription
sourceDirectory !-No description provided
pkgString !-No description provided
args[String ! ] -No description provided
Example
dagger -m github.com/z5labs/devex/daggerverse/go@a2dcd31837c97808f0699a6d70bb0bd34d97b8ab call \
 run --source DIR_PATH --pkg string
func (m *MyModule) Example(ctx context.Context, source *dagger.Directory, pkg string) string  {
	return dag.
			Go().
			Run(ctx, source, pkg)
}
@function
async def example(source: dagger.Directory, pkg: str) -> str:
	return await (
		dag.go()
		.run(source, pkg)
	)
@func()
async example(source: Directory, pkg: string): Promise<string> {
	return dag
		.go()
		.run(source, pkg)
}

spdx() 🔗

Spdx renders an SPDX 2.3 JSON document describing the module graph compiled into binary.

Why 2.3 and not 3.0. The version is chosen for what consumers ingest rather than left to whatever the library defaults to. SPDX 2.3 is the revision behind ISO/IEC 5962’s successor line that GitHub’s dependency graph, Dependency-Track, Grype, Trivy and the CISA/NTIA minimum-elements tooling all read today; 3.0 changes the serialization wholesale and support for it is still thin. A document nothing can parse is not an SBOM.

The subject is the binary, not the tree. The component list is read out of the compiled artifact with debug/buildinfo, so it names the modules that were actually linked in — not everything go.mod happens to require. source is an input and not the subject: a Go binary embeds module paths, versions and hashes but no licence text, so the licences have to be resolved from the module cache the source pins.

Licences are declared and concluded separately. Licence identification is a classifier, and a classifier reports coverage rather than a verdict. The classifier’s best match is always recorded as the declared licence; it is only promoted to the concluded licence when the match covers essentially the whole file. Anything less concludes NOASSERTION, so a low-confidence match cannot be mistaken downstream for an established one.

Return Type
File !
Arguments
NameTypeDefault ValueDescription
binaryFile !-

The compiled Go binary the document describes.

sourceDirectory !-

The source tree the binary was built from. Used to resolve the licence of each linked module; never used to enumerate components.

Example
dagger -m github.com/z5labs/devex/daggerverse/go@a2dcd31837c97808f0699a6d70bb0bd34d97b8ab call \
 spdx --binary file:path --source DIR_PATH
func (m *MyModule) Example(binary *dagger.File, source *dagger.Directory) *dagger.File  {
	return dag.
			Go().
			Spdx(binary, source)
}
@function
def example(binary: dagger.File, source: dagger.Directory) -> dagger.File:
	return (
		dag.go()
		.spdx(binary, source)
	)
@func()
example(binary: File, source: Directory): File {
	return dag
		.go()
		.spdx(binary, source)
}

test() 🔗

Test runs go test -count=1 [-race] [flags] pkg against the supplied source and returns the combined stdout. -count=1 is always passed to bypass Go’s internal test cache.

Return Type
String !
Arguments
NameTypeDefault ValueDescription
sourceDirectory !-No description provided
pkgString !"./..."No description provided
raceBoolean !falseNo description provided
flags[String ! ] -No description provided
Example
dagger -m github.com/z5labs/devex/daggerverse/go@a2dcd31837c97808f0699a6d70bb0bd34d97b8ab call \
 test --source DIR_PATH --pkg string --race boolean
func (m *MyModule) Example(ctx context.Context, source *dagger.Directory, pkg string, race bool) string  {
	return dag.
			Go().
			Test(ctx, source, pkg, race)
}
@function
async def example(source: dagger.Directory, pkg: str, race: bool) -> str:
	return await (
		dag.go()
		.test(source, pkg, race)
	)
@func()
async example(source: Directory, pkg: string, race: boolean): Promise<string> {
	return dag
		.go()
		.test(source, pkg, race)
}

toolVersion() 🔗

ToolVersion runs go version in a source-less base container and returns the trimmed output (e.g. “go version go1.23.0 linux/amd64”).

Return Type
String !
Example
dagger -m github.com/z5labs/devex/daggerverse/go@a2dcd31837c97808f0699a6d70bb0bd34d97b8ab call \
 tool-version
func (m *MyModule) Example(ctx context.Context) string  {
	return dag.
			Go().
			Toolversion(ctx)
}
@function
async def example() -> str:
	return await (
		dag.go()
		.toolversion()
	)
@func()
async example(): Promise<string> {
	return dag
		.go()
		.toolVersion()
}

vet() 🔗

Vet runs go vet pkg against the supplied source. pkg defaults to ./.... Returns a non-nil error when vet reports any issue.

Return Type
Void !
Arguments
NameTypeDefault ValueDescription
sourceDirectory !-No description provided
pkgString !"./..."No description provided
Example
dagger -m github.com/z5labs/devex/daggerverse/go@a2dcd31837c97808f0699a6d70bb0bd34d97b8ab call \
 vet --source DIR_PATH --pkg string
func (m *MyModule) Example(ctx context.Context, source *dagger.Directory, pkg string)   {
	return dag.
			Go().
			Vet(ctx, source, pkg)
}
@function
async def example(source: dagger.Directory, pkg: str) -> None:
	return await (
		dag.go()
		.vet(source, pkg)
	)
@func()
async example(source: Directory, pkg: string): Promise<void> {
	return dag
		.go()
		.vet(source, pkg)
}

work() 🔗

Work runs go work <subcommand> [args...] against the supplied source and returns stdout. subcommand is required (e.g. “init”, “use”, “sync”, “version”).

Return Type
String !
Arguments
NameTypeDefault ValueDescription
sourceDirectory !-No description provided
subcommandString !-No description provided
args[String ! ] -No description provided
Example
dagger -m github.com/z5labs/devex/daggerverse/go@a2dcd31837c97808f0699a6d70bb0bd34d97b8ab call \
 work --source DIR_PATH --subcommand string
func (m *MyModule) Example(ctx context.Context, source *dagger.Directory, subcommand string) string  {
	return dag.
			Go().
			Work(ctx, source, subcommand)
}
@function
async def example(source: dagger.Directory, subcommand: str) -> str:
	return await (
		dag.go()
		.work(source, subcommand)
	)
@func()
async example(source: Directory, subcommand: string): Promise<string> {
	return dag
		.go()
		.work(source, subcommand)
}

Ci 🔗

Ci is a chained builder for a standardized Go CI pipeline. Construct via Go.Ci(source); enable stages via the With* methods; call Run to execute checks-then-build, or Check to run only the parallel checks.

Stage 1 runs the enabled static checks in parallel (Fmt, Vet, Lint, Test); errors are aggregated. Stage 2 builds the source and Run returns the produced binary as a *dagger.File. Downstream consumers compose that file into their own pipelines (package, sign, publish, …).

check() 🔗

Check runs the enabled check stages (Fmt, Vet, Lint, Test) in parallel via github.com/dagger/dagger/util/parallel and returns the aggregated error. Use when callers want to run the checks independently of the build (for example multi-platform pipelines that share one check run across N platform builds).

Return Type
Void !
Example
dagger -m github.com/z5labs/devex/daggerverse/go@a2dcd31837c97808f0699a6d70bb0bd34d97b8ab call \
 ci --source DIR_PATH \
 check
func (m *MyModule) Example(ctx context.Context, source *dagger.Directory)   {
	return dag.
			Go().
			Ci(source).
			Check(ctx)
}
@function
async def example(source: dagger.Directory) -> None:
	return await (
		dag.go()
		.ci(source)
		.check()
	)
@func()
async example(source: Directory): Promise<void> {
	return dag
		.go()
		.ci(source)
		.check()
}

run() 🔗

Run executes the pipeline: stage 1 (Check) → stage 2 (build). Returns the built binary as a *dagger.File. On stage-1 failure, returns the aggregated error from Check and a nil file (stage 2 is skipped).

Return Type
File !
Example
dagger -m github.com/z5labs/devex/daggerverse/go@a2dcd31837c97808f0699a6d70bb0bd34d97b8ab call \
 ci --source DIR_PATH \
 run
func (m *MyModule) Example(source *dagger.Directory) *dagger.File  {
	return dag.
			Go().
			Ci(source).
			Run()
}
@function
def example(source: dagger.Directory) -> dagger.File:
	return (
		dag.go()
		.ci(source)
		.run()
	)
@func()
example(source: Directory): File {
	return dag
		.go()
		.ci(source)
		.run()
}

withBuild() 🔗

WithBuild configures the build stage parameters. pkg defaults to “.” when empty; binaryName defaults to the basename of the module directive in go.mod when empty. Build is always executed by Run regardless of whether this method is called.

Note: the binary-name flag is called binaryName (CLI: –binary-name) to avoid colliding with Dagger CLI’s top-level –output/-o flag.

Return Type
Ci !
Arguments
NameTypeDefault ValueDescription
pkgString -No description provided
binaryNameString -No description provided
Example
dagger -m github.com/z5labs/devex/daggerverse/go@a2dcd31837c97808f0699a6d70bb0bd34d97b8ab call \
 ci --source DIR_PATH \
 with-build
func (m *MyModule) Example(source *dagger.Directory) *dagger.GoCi  {
	return dag.
			Go().
			Ci(source).
			Withbuild()
}
@function
def example(source: dagger.Directory) -> dagger.GoCi:
	return (
		dag.go()
		.ci(source)
		.withbuild()
	)
@func()
example(source: Directory): GoCi {
	return dag
		.go()
		.ci(source)
		.withBuild()
}

withFmt() 🔗

WithFmt enables the gofmt check stage.

Return Type
Ci !
Example
dagger -m github.com/z5labs/devex/daggerverse/go@a2dcd31837c97808f0699a6d70bb0bd34d97b8ab call \
 ci --source DIR_PATH \
 with-fmt
func (m *MyModule) Example(source *dagger.Directory) *dagger.GoCi  {
	return dag.
			Go().
			Ci(source).
			Withfmt()
}
@function
def example(source: dagger.Directory) -> dagger.GoCi:
	return (
		dag.go()
		.ci(source)
		.withfmt()
	)
@func()
example(source: Directory): GoCi {
	return dag
		.go()
		.ci(source)
		.withFmt()
}

withLint() 🔗

WithLint enables the golangci-lint check stage. version pins the installed golangci-lint version (defaults to defaultGolangciLintVersion when empty). config, if non-nil, is mounted at golangciLintConfigMountPath and passed to golangci-lint via –config.

Return Type
Ci !
Arguments
NameTypeDefault ValueDescription
versionString -No description provided
configFile -No description provided
Example
dagger -m github.com/z5labs/devex/daggerverse/go@a2dcd31837c97808f0699a6d70bb0bd34d97b8ab call \
 ci --source DIR_PATH \
 with-lint
func (m *MyModule) Example(source *dagger.Directory) *dagger.GoCi  {
	return dag.
			Go().
			Ci(source).
			Withlint()
}
@function
def example(source: dagger.Directory) -> dagger.GoCi:
	return (
		dag.go()
		.ci(source)
		.withlint()
	)
@func()
example(source: Directory): GoCi {
	return dag
		.go()
		.ci(source)
		.withLint()
}

withTest() 🔗

WithTest enables the go test ./... check stage. Pass race=true to enable the data-race detector.

Return Type
Ci !
Arguments
NameTypeDefault ValueDescription
raceBoolean -No description provided
Example
dagger -m github.com/z5labs/devex/daggerverse/go@a2dcd31837c97808f0699a6d70bb0bd34d97b8ab call \
 ci --source DIR_PATH \
 with-test
func (m *MyModule) Example(source *dagger.Directory) *dagger.GoCi  {
	return dag.
			Go().
			Ci(source).
			Withtest()
}
@function
def example(source: dagger.Directory) -> dagger.GoCi:
	return (
		dag.go()
		.ci(source)
		.withtest()
	)
@func()
example(source: Directory): GoCi {
	return dag
		.go()
		.ci(source)
		.withTest()
}

withVet() 🔗

WithVet enables the go vet ./... check stage.

Return Type
Ci !
Example
dagger -m github.com/z5labs/devex/daggerverse/go@a2dcd31837c97808f0699a6d70bb0bd34d97b8ab call \
 ci --source DIR_PATH \
 with-vet
func (m *MyModule) Example(source *dagger.Directory) *dagger.GoCi  {
	return dag.
			Go().
			Ci(source).
			Withvet()
}
@function
def example(source: dagger.Directory) -> dagger.GoCi:
	return (
		dag.go()
		.ci(source)
		.withvet()
	)
@func()
example(source: Directory): GoCi {
	return dag
		.go()
		.ci(source)
		.withVet()
}