cmdhooks

package
v0.182.6 Latest Latest
Warning

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

Go to latest
Published: Oct 6, 2026 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

New registers the complete hooks family with per-command operations.

Types

type AgentOperations

type AgentOperations struct {
	Inspect         func(agentguard.ToolCall, agentguard.Options) agentguard.Decision
	OpenInput       func(string) (io.ReadCloser, error)
	Executable      func() string
	ResolveGovernor func(string) string
	Home            func() (string, error)
	MergeSettings   func(string, string) ([]byte, bool, error)
	WriteSettings   func(string, []byte) error
	Quote           func(string) string
}

AgentOperations isolate protocol argument handling from actual policy and settings writes.

type CheckError

type CheckError struct {
	Count int
	Fleet bool
}

func (*CheckError) Error

func (e *CheckError) Error() string

type DrainOptions

type DrainOptions struct {
	ConfigPath, StateDir, ReceiptPath string
	Parallel                          int
}

DrainOptions transport only the hidden durable-worker command's arguments.

type GitOperations

type GitOperations struct {
	Apply      func(hooks.ApplyOptions) (hooks.ApplyResult, error)
	Check      func(string, string, string, string) (hooks.CheckReport, error)
	LocalRepos func(string, string) ([]discover.Repo, error)
	Run        func(hooks.RunOptions) (hooks.RunResult, error)
	Classify   func(io.Reader, string) (hooks.Classification, error)
	LoadPolicy func(string, string) (hooks.Policy, error)
	ReadEvents func(string) ([]hooks.Event, error)
	Executable func() string
	Now        func() time.Time
	Exit       func(int)
}

GitOperations are the existing hook service boundaries used by these commands.

type LifecycleOperations

LifecycleOperations keep mutable dispatcher instances below the CLI boundary.

Jump to

Keyboard shortcuts

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