executable

package
v0.1.8-rc.9 Latest Latest
Warning

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

Go to latest
Published: Mar 13, 2026 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Overview

Package executable provides a generic tool wrapper for arbitrary binaries.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Name        string   `yaml:"name" toml:"name"`
	Binary      string   `yaml:"binary" toml:"binary"`
	Description string   `yaml:"description" toml:"description"`
	Env         []EnvVar `yaml:"env,omitempty" toml:"env,omitempty"`
}

Config holds the configuration for a generic executable tool.

func (Config) Tool

func (cfg Config) Tool(ctx context.Context, sp security.SecretProvider) (tool.Tool, error)

Tool validates the configuration and returns an executable tool.

type Configs

type Configs []Config

Configs represents a list of executable tool configurations.

func (Configs) Tools

func (c Configs) Tools(ctx context.Context, sp security.SecretProvider) []tool.Tool

Tools resolves secrets and validates binary availability, converting valid configurations into tool.Tool instances.

type EnvVar

type EnvVar struct {
	Key    string `yaml:"key" toml:"key"`
	Value  string `yaml:"value,omitempty" toml:"value,omitempty"`
	Secret string `yaml:"secret,omitempty" toml:"secret,omitempty"`
}

EnvVar represents an environment variable key-value pair, or a lookup.

Jump to

Keyboard shortcuts

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