Documentation
¶
Overview ¶
Package exit is bitc's exit-code contract (spec 4). Every bitc outcome that is not the command's own exit code is an *Error carrying its code and the exact stderr line.
Index ¶
- Constants
- func Code(err error) int
- func Go(fn func())
- type Error
- func As(err error) *Error
- func Configf(format string, a ...any) *Error
- func Internal(v any) *Error
- func LinuxOnly(feature, goos string) *Error
- func NoInputf(format string, a ...any) *Error
- func Refused(pool, reason string) *Error
- func Starved(pool, reason string) *Error
- func Unavailablef(format string, a ...any) *Error
- func Usagef(format string, a ...any) *Error
Constants ¶
const ( OK = 0 Usage = 64 // EX_USAGE: fix the call NoInput = 66 // EX_NOINPUT: no such job TempFail = 75 // EX_TEMPFAIL: starved; wait and retry Config = 78 // EX_CONFIG: fix config StillRunning = 124 // wait: job still running // TimedOut is the same 124, as timeout(1) exits: a local run ended by its time limit // (pools.<p>.timeout, run --timeout). Told apart from StillRunning by the verb. TimedOut = StillRunning )
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Error ¶
Error is a bitc outcome. Line is printed verbatim to stderr (no trailing newline); Outcome and Reason go to result.json (spec 4).
func Internal ¶
Internal is a bitc bug: 69, never 75 (a bug that fails every time must not loop a retrying agent) and never Go's 2.
func LinuxOnly ¶
LinuxOnly is the one refusal of a Linux-only feature in a non-Linux client build: 69, like "not Linux" (docs/exit-codes.md). feature takes a singular verb ("the remote agent").