hook

package
v0.2.2 Latest Latest
Warning

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

Go to latest
Published: Apr 14, 2026 License: MIT Imports: 4 Imported by: 0

Documentation

Overview

Package hook handles the hook event lifecycle. It reads hook events from stdin, hands them to the local evaluator, and writes the resulting decision to stdout.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Run

func Run(a agent.Agent, evaluate func(*agent.HookEvent) (bool, string, error))

Run processes a single hook event. Called by `kontext hook --agent <name>`. Reads JSON from stdin, decodes via the agent adapter, evaluates the event, and writes the decision to stdout/stderr with the appropriate exit code.

Types

This section is empty.

Jump to

Keyboard shortcuts

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