cmd

package
v2.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 15, 2026 License: MIT Imports: 35 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package cmd wires up atlio's cobra command tree.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Execute

func Execute(version string) int

Execute runs the root command, reporting version for --version, and returns the process exit code: 0 when it succeeded, 124 when the --timeout deadline expired, and 1 for every other failure. Those numbers are the contract a caller reads, so they are spelled out here rather than named. The error itself is printed rather than returned, since main has nothing left to do with it.

The code comes back from a function that returns normally because os.Exit skips deferred functions, so main can do nothing but pass it straight on.

Nothing here catches a signal: an interrupt ends the process through the Go default, so no error unwinds the stack and this never runs for one — an interrupted run has no exit code at all, only a termination status. The one place that does catch is the masked token read, where the terminal has to be put back first (see terminalGuard in auth.go).

The command context is left unset: cobra defaults a nil one to context.Background(), which is all commandContext needs to derive from.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL