Discover Packages
github.com/danmestas/bones
internal
workspace
package
Version:
v0.1.0
Opens a new window with list of versions in this module.
Published: Apr 27, 2026
License: Apache-2.0
Opens a new window with license information.
Imports: 21
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
Documentation
Documentation
¶
Package workspace manages a bones workspace: the .agent-infra/
directory, its on-disk config, and the associated leaf daemon process.
Two entry points:
Init creates a fresh workspace and starts a leaf daemon.
Join locates an existing workspace (walking up from cwd) and verifies
its leaf is reachable.
View Source
var (
ErrAlreadyInitialized = errors .New ("workspace already initialized")
ErrNoWorkspace = errors .New ("no bones workspace found")
ErrLeafUnreachable = errors .New ("leaf daemon not reachable")
ErrLeafStartTimeout = errors .New ("leaf daemon failed to start within timeout")
)
ExitCode maps errors returned by Init and Join to conventional process exit
codes: 0 on success, 2-5 for known sentinels, 1 for anything else. Callers
that want a different convention can inspect errors directly.
Info describes a live workspace. Returned by both Init and Join.
Init creates a fresh workspace rooted at cwd, starts a leaf daemon, and
returns its connection info. Returns ErrAlreadyInitialized if .agent-infra/
already exists in cwd.
Join locates the nearest .agent-infra/ walking up from cwd and verifies
the recorded leaf is still reachable.
Source Files
¶
Click to show internal directories.
Click to hide internal directories.